Jump to content

Recommended Posts

can you tell me this link below what proper way to include a php variable 

 

<iframe src="https://www.superrewards-offers.com/super/offers?h=hhyyhdhd.912853523890&uid=USER_ID" frameborder="0" width="728" height="2400" scrolling="no"></iframe>

need to add $username to the USER_ID part

 

I tried just

<iframe src="https://www.superrewards-offers.com/super/offers?h=hhyyhdhd.912853523890&uid=$username" frameborder="0" width="728" height="2400" scrolling="no"></iframe>

should that not work??? I thought it would but - superrewards app don't show and I thinking might be casue this is not bring in the username 

Link to comment
https://forums.phpfreaks.com/topic/285961-php-variable-in-href-link/
Share on other sites

That syntax is correct.

No the syntax is correct for the HTML, but PHP code is only parsed if it is within <?php ?> tags.

 

@desjardins2010, have you tried

<iframe src="https://www.superrewards-offers.com/super/offers?h=hhyyhdhd.912853523890&uid=<?php echo $username; ?>" frameborder="0" width="728" height="2400" scrolling="no"></iframe>
Edited by Ch0cu3r

The answer is in post #3 by ch0cu3r :

 

@desjardins2010, have you tried

<iframe src="https://www.superrewards-offers.com/super/offers?h=hhyyhdhd.912853523890&uid=<?php echo $username; ?>" frameborder="0" width="728" height="2400" scrolling="no"></iframe>

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.