Page 1 of 2 12 LastLast
Results 1 to 10 of 11

Thread: I want to redirect the URL after submitting the posts |HOW?|

  1. #1
    Junior Member mydomaindesk's Avatar
    Joined
    Nov 2012
    Posts
    13

    Question I want to redirect the URL after submitting the posts |HOW?|

    HI Everyone,

    When someone submits the post, then they come in upcoming.php page, i want to know how can i redirect in my different page just like topusers page...THANKS

  2. #2
    Pligg Developer/Coder/Designer ChuckRoast's Avatar
    Joined
    Dec 2005
    Location
    Pliggville USA
    Posts
    9,118
    Not sure this will work but it's worth a shot.
    Open submit.php and ion line 541 you will see
    Code:
    header("Location: " . getmyurl('upcoming'));
    Try changing to
    Code:
    header("Location: " . getmyurl('topstories'));
    Then make sure you clear your template cache from the administration panel.
    Hope that helps
    Help Keep ChuckRoast Home
    Today's Pligg Blog Post


  3. #3
    Junior Member mydomaindesk's Avatar
    Joined
    Nov 2012
    Posts
    13
    Hi,

    Can i redirect on my another website after submitting the story, just like when member submits story then they will redirect on this website p-r.biz?

  4. #4
    Pligg Developer/Coder/Designer ChuckRoast's Avatar
    Joined
    Dec 2005
    Location
    Pliggville USA
    Posts
    9,118
    Try changing it to something like this
    Code:
    header('Location: http://www.example.com/');
    Don't forget to clear you cache from the administration panel after you make changes.
    Help Keep ChuckRoast Home
    Today's Pligg Blog Post


  5. #5
    Junior Member mydomaindesk's Avatar
    Joined
    Nov 2012
    Posts
    13
    Hi,

    I have used it
    Code:
    header('Location: http://www.p-r.biz/');
    but my site page submit.php has got down and its showing (Internal Server Error)

  6. #6
    Pligg Developer/Coder/Designer ChuckRoast's Avatar
    Joined
    Dec 2005
    Location
    Pliggville USA
    Posts
    9,118
    That's not good.
    Give this a shot
    Code:
    header("Location: " . 'http://www.p-r.biz/');
    Help Keep ChuckRoast Home
    Today's Pligg Blog Post


  7. #7
    Junior Member mydomaindesk's Avatar
    Joined
    Nov 2012
    Posts
    13
    Its not working same problem,

    Code:
    }
    	$vars = array('linkres'=>$linkres);
    	check_actions('submit_pre_redirect', $vars);
    	if ($vars['redirect'])
    	    header('Location: " . 'http://www.p-r.biz/'); '.$vars['redirect']);
    	elseif($linkres->link_group_id == 0)
    		header("Location: " . getmyurl('upcoming'));
    	else
    	{

  8. #8
    Pligg Developer/Coder/Designer ChuckRoast's Avatar
    Joined
    Dec 2005
    Location
    Pliggville USA
    Posts
    9,118
    I see 2 problems
    I told you to modify line 541 but you modified line 539
    I told you to try this

    Code:
    header("Location: " . 'http://www.p-r.biz/');
    You didn't do that, you did
    Code:
    header('Location: " . 'http://www.p-r.biz/');
    You used a single quote where it should be a double quote.
    Please make sure you follow instructions better.
    I can't spend any more free time helping you customize your site. Sorry. I can only suggest reading up on how to program or recommend that you hire someone to do it for you.
    Help Keep ChuckRoast Home
    Today's Pligg Blog Post


  9. #9
    Junior Member mydomaindesk's Avatar
    Joined
    Nov 2012
    Posts
    13
    Realy sorry friend, i did not notice, but i have again used here and its not opening, its not going to submit page. There is same promblem...

    Code:
    $vars = array('linkres'=>$linkres);
    	check_actions('submit_pre_redirect', $vars);
    	if ($vars['redirect'])
    	    header('Location: '.$vars['redirect']);
    	elseif($linkres->link_group_id == 0)
    		header("Location: " . 'http://www.p-r.biz/'); " . getmyurl('upcoming'));
    	else
    Last edited by mydomaindesk; 01-08-2013 at 05:42 PM.

  10. #10
    Pligg Developer/Coder/Designer ChuckRoast's Avatar
    Joined
    Dec 2005
    Location
    Pliggville USA
    Posts
    9,118
    Again
    Code:
    header("Location: " . 'http://www.p-r.biz/');
    Is not
    Code:
    header("Location: " . 'http://www.p-r.biz/'); " . getmyurl('upcoming'));
    Help Keep ChuckRoast Home
    Today's Pligg Blog Post


Page 1 of 2 12 LastLast

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •