Php sözdizimi hatası, biraz yardım

2 Cevap php

Ben bu dizesi vardır:

$imagename ="$ad_id_stripped"."_1".".jpg";
$display_table.="<a href='../ad.php?ad_id=$row[ad_id]' target='_parent'>
<img style='border:none;' src='../ad_images/$category/thumbs/$imagename?time()' class='shadow'></a>";

echo $display_table;

As you maybe can see I am trying to add the time() function in there... However, there is no time() added to it like this! I have tried with various quotes etc without luck...

Herhangi bir fikir?

Teşekkürler

2 Cevap

$imagename ="$ad_id_stripped"."_1".".jpg";
$display_table.="<a href='../ad.php?ad_id=$row[ad_id]' target='_parent'>
<img style='border:none;' src='../ad_images/$category/thumbs/$imagename?" . time() . "' class='shadow'></a>";

echo $display_table;

Sen dize kendisi dışında time() işlevi almak ve birleştirmek istiyorum

Bunu yapamazsınız:

$string = "....time()...";

Yapmanız gereken:

$string = "..." . time() . "....";

veya

$time = time();
$string = "....$time...";