Jump to content

Can Anyone Help Me...


subhomoy

Recommended Posts

I got a script from somewhere on google and found that it contains a "dynamic div" tag i.e see below

<div id="ad<?php echo $fn; ?>"> // [color=#ff0000]This is the place where i'm facing problem...[/color]
<a href="index.php?tp=visit_task&t=<?php echo $fn; ?>&id=<?php echo $fn; ?>" target='_blank' onclick='hideDivTag("ad<?php echo $fn; ?>");'><?php echo $fsitename; ?></a>
 ( You earn:
<?php
if($fpaytype=='points') { ?><?php echo $prise; ?> <?php echo $setupinfo['pointsName']; ?>(s)<?php }
else if($fpaytype=='usd') echo $setupinfo['currency']."$prise";
?> ) <BR /><BR /></div><?php
$clicks++;
}
}
}
?><br />
</div>

 

 

when this code is seen in browser it looks like this

<div id="ad44">
<a href="index.php?tp=visit_task&t=44&id=44" target='_blank' onclick='hideDivTag("ad44");'>Google</a>
 ( You earn:
Rs 0.001000 ) <BR /><BR /></div>			 <div id="ad45"> // [color=#ff0000]This One[/color]
<a href="index.php?tp=visit_task&t=45&id=45" target='_blank' onclick='hideDivTag("ad45");'>156</a>
 ( You earn:
Rs 0.001000 ) <BR /><BR /></div>			 <div id="ad47">// [color=#ff0000]This One[/color]
<a href="index.php?tp=visit_task&t=47&id=47" target='_blank' onclick='hideDivTag("ad47");'>123</a>
 ( You earn:
Rs 0.001000 ) <BR /><BR /></div>			 <div id="ad49"> //[color=#ff0000]This One[/color]
<a href="index.php?tp=visit_task&t=49&id=49" target='_blank' onclick='hideDivTag("ad49");'>789</a>
 ( You earn:
Rs 0.001000 ) <BR /><BR /></div>			 <div id="ad50"> //[color=#ff0000]This One[/color]
<a href="index.php?tp=visit_task&t=50&id=50" target='_blank' onclick='hideDivTag("ad50");'>459</a>
 ( You earn:
Rs 0.001000 ) <BR /><BR /></div><br />
<br />

</div>

 

see that every div tags automatically assigns a number beside it..

 

I want to add new style of this div but can't do that as it is changing randomly whenever new ads is posted and i also can't find the #ad in the .css also.....

 

can anyone help me....

 

Thanks in advance...

Link to comment
Share on other sites

Then don't use the ID to apply the style properties! Every element must have a unique ID. But, you can give many elements that same class. So, modify the code to apply a class to the divs then define the class in your CSS file.

 

Can you plz give a bit of detail....

Thanks for the reply...

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.