By zareen on
Thanks in advance to anyone who can help me out with this!!
I am making a change in ed_classified module. I want the contact link to go to the node creator's contact form, and drop the node ID into the subject using prepopulate module.
Everything is working perfectly except the ? turns to %3F, the [ turns to %5B, the ] turns to %5D, and the = turns to %3D
here's the code line
'href' => 'user/'. $ad_author->uid .'/contact?edit[subject]='. $node->nid,
so I get this: user/3/contact%3Fedit%5Bsubject%5D%3D78
instead of this: user/3/contact?edit[subject]=78
Comments
urldecode
Tried urldecode and it didn't work
'href' => 'user/'. $ad_author->uid .'/contact'.urldecode('%3Fedit%5Bsubject%5D%3D'). $node->nid,returned the same string
fixing link encoding
Figured it out, so I'm posting the answer in case anyone else is looking for how to stop a link from encoding.
What I had to do was find where the links were getting called and (of course) that is in node-ed_classified.tpl.php in my theme.
I changed
print $links;toprint rawurldecode($links);There is a sample node-ed_classified.tpl.php in the ed_classified module. Make necessary changes to it and upload to your theme folder and it will fire.
THANKS
I spent three hours unsuccessfully until I found your post.
Thanks very much
Thanks
Good find :)