Jump to content

Recommended Posts

Hi All,

 

Sorry for posting what you might consider a very basic issue, but I've been tearing my hair out for 2 hours on this. In a nutshell I cannot get my rating score images to align horizontally, they keep going vertically, which is not what I want. I have copied my code that is produced from my php script into another page and the images are diaplayed correctly. Annoyingly i cannot for the life of me work out why they are displaying vertically.

 

http://www.jungletekno.co.uk/mixes.php

 

On the right you can see the small images which should be going horizontally. I have tried making them really small to see if taht was the issue. Any ideas what i'm doing wrong? Code is below-

 

code.....

 

$half = "<img src='pictures/half.png' height='5' width='5' />";

$full = "<img src='pictures/full.png' height='5' width='5' />";

$empty = "<img src='pictures/empty.png' height='5' width='5' />";

 

loads of code between here

 

}else if($rounded_rating > 1 && $rating <= 1.5){

echo $full.$half.$empty.$empty.$empty;

{

 

}

echo $rounded_rating . $rating_max ?> <br>

<? echo $rating_number .  $rating_voters

?>

<form method="post" action="<? echo $_SERVER['PHP_SELF']; ?>?t=temp">

<p><select name="votes">

<option value="">Choose a Rating</option>

<option value="5">I Love It!</option>

<option value="4">Good</option>

<option value="3">Moderate</option>

<option value="2">Not Bad</option>

<option value="1">Poor</option>

</select><br />

<input type="submit" name="v_submit" value=" Rate It! " /></p>

</form>

 

</td> </tr>

Link to comment
https://forums.phpfreaks.com/topic/50949-annoying-problem-with-ratings-images/
Share on other sites

I don't think you have a PHP problem.  Your code is not outputting any line breaks and looking at the source code on your site, it looks fine.  Perhaps there's something in the table cell properties or CSS that causing the problem?

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.