Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7567167
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 30, 20262026-05-30T14:35:52+00:00 2026-05-30T14:35:52+00:00

I have a view that add and edit Meeting objects and I’m going to

  • 0

I have a view that add and edit Meeting objects and I’m going to after saving a Meeting object show a list of participants of that object,how can I return a list of participants with HttpResponseRedirect ? I don’t think it be possible to send a big list of objects via query string !

in views.py

def addMeeting(request,meeting_id=None):
   message=u''
   participants=Participant.objects.filter(meeting__id=meeting_id)
   if request.GET.get('save'):
      message='your recorded was registered'
   if meeting_id:
      meeting_instance=Meeting.objects.get(pk=meeting_id)
   else:
      meeting_instance=Meeting()
   if request.method=='POST':
      meetingform=MeetingForm(request.POST,instance=meeting_instance)
      if meetingform.is_valid():
         meeting=meetingform.save()
         meeting.save()
         redirect_url=reverse('MeetingManagerHub.views.addMeeting', args=[meeting.pk])
         return HttpResponseRedirect(redirect_url+'?save=True')
   else:
      meetingform=MeetingForm(instance=meeting_instance)
   return render_to_response('MeetingHub/addmeeting.html', {'meetingform': meetingform,'message':message},context_instance=RequestContext(request))

in urls.py

(r'^meeting/add/$','MeetingManagerHub.views.addMeeting'),
(r'^meeting/add/(?P<meeting_id>\d+)/$','MeetingManagerHub.views.addMeeting'),

I googled alot and finally found out that HttpResponseRedirect just redirect us to a new address and doesn’t work with context!

how can I do this?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-30T14:35:53+00:00Added an answer on May 30, 2026 at 2:35 pm

    There’s a secret to this. A Redirect should points to a view which gets the meeting AND the participants.

    Often, that’s a simple view function that handles simple GET requests and returns the meeting and the list of participants.

    If you’re going to redirect back to this addMeeting view function, then the GET processing needs to query meetings AND the participants.
    That means that the render_to_response must include the meeting AND the participants.

    return render_to_response('MeetingHub/addmeeting.html', 
        {'meetingform': meetingform, 'message':message,
        'meeting': meeting, 'participants': participants,
        #... and anything else that might be helpful to show on the page
        },
        context_instance=RequestContext(request))
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have a view function that allows a user to Add / Edit /
I have a view that I want to add some custom drawing to. I
I have a for loop that creates multiple UIImageViews that I add to self.view
I have a view that has a list of jobs in it, with data
I have an NSTableView that I add objects to (through core data). I came
I have a LinearLayout view that I am trying to add a divider to
I currently have a view, manage, that lists data items. Instead of running edit
I have a table view that displays a list that I want the user
I have and add/edit form that adds/edits depending on whether there is an id
Trying to create a page that allows users to add edit and view a

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.