Jump to content

php syntax help passing a variable and more


php_begins

Recommended Posts

I probably need synatx help or more:

I have a page that has the following code for an image:

 

<?php echo "<a href='".$gallery_folder.$photo_name."' >"; ?>

<img src="<?php echo $imagespath.$row['Photo_path'].$row['Thumbnail1_name']; ?>" /></a>

 

This takes you to this page:

http://www.xyz.com/photo/a_home_a-433.html

 

 

Now, i need to pass a variable to the above page so that when it redirects I get the following information on the URL:

http://www.xyz.com/photo/a_home_a-433.html?album='some-album-name'.

 

I tried different things but i am still getting an error in the page.

 

This one of the things I tried:

<a href="<?php echo $gallery_folder.$photo_name; ?>?album=<?php echo $category_name; ?>

<img src="<?php echo $imagespath.$row['Photo_path'].$row['Thumbnail1_name']; ?>" /></a>

 

I need help with the syntax.

 

 

Link to comment
Share on other sites

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.