[SOLVED]Tracking ?id= and Pretty URLs

For questions and problems with the CMS core. This board is NOT for any 3rd party modules, addons, PHP scripts or anything NOT distributed with the CMS made simple package itself.
Post Reply
adsilva
New Member
New Member
Posts: 7
Joined: Thu Jan 31, 2008 7:32 pm

[SOLVED]Tracking ?id= and Pretty URLs

Post by adsilva »

I'm trying to pass a Tracking id into aweber by either placing the id into the meta_adtracking field or creating a hidden field.
"> see below

I have tried placing the aweber code into a smarty tag:

Code: Select all

echo
<center><form method="post" action="http://www.aweber.com/scripts/addlead.pl">
<input type="hidden" name="meta_web_form_id" value="xxxxxxxxxxx">
<input type="hidden" name="meta_split_id" value="">
<input type="hidden" name="unit" value="testpba">
<input type="hidden" name="redirect" value="http://www.aweber.com/form/thankyou_vo.html" id="redirect_xxxxxx">
<input type="hidden" name="meta_redirect_onlist" value="">
<input type="hidden" name="meta_adtracking" value="<?php echo $tid; ?>">
<input type="hidden" name="meta_message" value="1">
<input type="hidden" name="meta_required" value="from">
<input type="hidden" name="meta_forward_vars" value="0">
<table>
<tr><td colspan=2><center></center></td></tr>
<tr><td>Name:</td><td><input type="text" name="name" value="" size="20"></td></tr>
<tr><td>Email:</td><td><input type="text" name="from" value="" size="20"></td></tr>
    <tr><td colspan=2><center></center></td></tr>
<tr><td align="center" colspan="2"><input type="submit" name="submit" value="Submit"></td></tr>
</table>
</form>

<img src="http://forms.aweber.com/form/displays.htm?id=jEzszKyMxxxx==" border="0" />
</center>
;
and in between my head tags I placed:

Code: Select all

<?php
$tid = $_REQUEST['tid'];
?>
I do have Pretty URLs turned on and my tracking url looks like this:

www.mysite.com/resources/p-b-a/?tid=andy

and i have tried without the final forward slash

www.mysite.com/resources/p-b-a?tid=andy

But in both instances the tid "andy" is not getting passed into the bolded line above.

any suggestions on this issue?

I read up on the internet that it may be because I don't have a ".php" extension.  Is this true?

thanks.
Last edited by adsilva on Fri Apr 17, 2009 2:38 am, edited 1 time in total.
JeremyBASS

Re: Tracking ?id= and Pretty URLs

Post by JeremyBASS »

Hello, in your config file you can add a .html/.php/.asp/.htm/.myOwn extension

aweber... sounds familiar...

if this is in your templates... then value="" should be

value="{$smarty.request.tid}"

then that would work... but that is if your in a template... in a udt... it's different...

Hope that helps
Cheers
Jeremy
adsilva
New Member
New Member
Posts: 7
Joined: Thu Jan 31, 2008 7:32 pm

Re: Tracking ?id= and Pretty URLs

Post by adsilva »

Jeremy, thank you for the reply.

So let me make sure I understand.

I HAVE to change my config file so that my pages end with .php or .htm

Then I can use the smarty tag ONLY if the script is part of my template and I cannot call it with a UDT into my page.

Is there a way I can call it into a page??
adsilva
New Member
New Member
Posts: 7
Joined: Thu Jan 31, 2008 7:32 pm

Re: Tracking ?id= and Pretty URLs

Post by adsilva »

What about...



would that pull "andy" from this url www.mysite.com/resources/p-b-a.php?tid=andy

or do I HAVE to use Smarty style tags?
JeremyBASS

Re: Tracking ?id= and Pretty URLs

Post by JeremyBASS »

>>I HAVE to change my config file so that my pages end with .php or .htm

Yes that is the sure fire way... and no if you’re really really good...

>>>Then I can use the smarty tag ONLY if the script is part of my template and I cannot call it with a UDT into my page.

No... and yes you could

>>>Is there a way I can call it into a page??

{$smarty.request.tid} is the way you would call it in a page/template/GCB basically any thing that is not a UDT or a php file it's self.

>>>>>>>>What about...
>>>>>>>> 


Depends on where you put it...


... so lets say for a sec... this is my project... I'd put that whole form in a page/GCB and to grab the tid... it'd look like this in the page...

Code: Select all


<center><form method="post" action="http://www.aweber.com/scripts/addlead.pl">
<input type="hidden" name="meta_web_form_id" value="xxxxxxxxxxx">
<input type="hidden" name="meta_split_id" value="">
<input type="hidden" name="unit" value="testpba">
<input type="hidden" name="redirect" value="http://www.aweber.com/form/thankyou_vo.html" id="redirect_xxxxxx">
<input type="hidden" name="meta_redirect_onlist" value="">
<input type="hidden" name="meta_adtracking" value="{$smarty.request.tid}">
<input type="hidden" name="meta_message" value="1">
<input type="hidden" name="meta_required" value="from">
<input type="hidden" name="meta_forward_vars" value="0">
<table>
<tr><td colspan=2><center></center></td></tr>
<tr><td>Name:</td><td><input type="text" name="name" value="" size="20"></td></tr>
<tr><td>Email:</td><td><input type="text" name="from" value="" size="20"></td></tr>
    <tr><td colspan=2><center></center></td></tr>
<tr><td align="center" colspan="2"><input type="submit" name="submit" value="Submit"></td></tr>
</table>
</form>

<img src="http://forms.aweber.com/form/displays.htm?id=jEzszKyMxxxx==" border="0" />
</center>


then you’re making less db calls and cutting to the chase...


Hope that helps...

Cheers
jeremyBass
Last edited by JeremyBASS on Fri Apr 17, 2009 2:13 am, edited 1 time in total.
adsilva
New Member
New Member
Posts: 7
Joined: Thu Jan 31, 2008 7:32 pm

Re: Tracking ?id= and Pretty URLs

Post by adsilva »

SOLVED!

Jeremy - U tha Man!!
JeremyBASS

Re: [SOLVED]Tracking ?id= and Pretty URLs

Post by JeremyBASS »

Glad I could help...
Cheers
jeremyBass
Post Reply

Return to “CMSMS Core”