PDA

View Full Version : Need help wrapping dynamic text block hooked to db



free city
Feb 25th, 2012, 04:26 AM
Does any one know how I can confine a block of dnamic text from going across the whole page thanks

Ie:

http://www.freecitylinks.com/a,3454,Corporate-Bankruptcy-%7C-Chapter-13-Lawyer-Connectic.htm

I found the code that brings in the text how do I make it so it is only 1000 px wide.
It is pushing the contact by email module down

I looked in the css and can't find anything
Thanks

sunfighter
Feb 25th, 2012, 04:58 PM
Since I can find one line that spreads across the page (This is not dnamic text so I might be in the wrong place. If so let us know where the dnamic text is generated please) I looked at it. It is between to span tags that do nothing see:

<span>
<p>The unfortunate fact is that the majority of Chapter 13 cases are unsuccessful, but the Lenz Law Firm has a higher than average success rate. We provide experienced assistance to people interested in getting a fresh start on their finances and their lives.
</p>
<p><strong>
Contact Info &amp; Business Hours<br /></strong><br />
Monday - Friday<br />&nbsp;&nbsp;&nbsp; 9 AM to 5 PM<br />
Saturday - Sunday<br />&nbsp;&nbsp;&nbsp; CLOSED<br /><br />
Phone:<br />&nbsp;&nbsp;&nbsp; (203) 747-8548 <br />
Fax:<br />&nbsp;&nbsp;&nbsp; (203) 799-0681<br />
Email:<br />&nbsp;&nbsp;&nbsp; [email protected]<br />
Address:<br />&nbsp;&nbsp;&nbsp; 236 Boston Post Road
<br />&nbsp;&nbsp;&nbsp; 2nd Floor<br />
&nbsp;&nbsp;&nbsp; Orange, CT 06477
</p>
</span>

Change the span tags to divs and add a width. I started with 300px; You adjust that for the effect you want:

<div style="width:300px;" >
<p>The unfortunate fact is that the majority of Chapter 13 cases are unsuccessful, but the Lenz Law Firm has a higher than average success rate. We provide experienced assistance to people interested in getting a fresh start on their finances and their lives.
</p>
<p><strong>
Contact Info &amp; Business Hours<br /></strong><br />
Monday - Friday<br />&nbsp;&nbsp;&nbsp; 9 AM to 5 PM<br />
Saturday - Sunday<br />&nbsp;&nbsp;&nbsp; CLOSED<br /><br />
Phone:<br />&nbsp;&nbsp;&nbsp; (203) 747-8548 <br />
Fax:<br />&nbsp;&nbsp;&nbsp; (203) 799-0681<br />
Email:<br />&nbsp;&nbsp;&nbsp; [email protected]<br />
Address:<br />&nbsp;&nbsp;&nbsp; 236 Boston Post Road
<br />&nbsp;&nbsp;&nbsp; 2nd Floor<br />
&nbsp;&nbsp;&nbsp; Orange, CT 06477
</p>
</div>

free city
Feb 25th, 2012, 07:25 PM
Ok thanks I will try that span would not take the width

free city
Feb 25th, 2012, 08:15 PM
still wont take it this is what the code looks like :

<div style="width:800px;" >$descr1</div>"; is the line that brings in the copy but the page goes blank with the width style.

$out.="<dd id=\"date\"><b>".__("Date listed")." :</b> $date</dd><div style="width:800px;" >$descr1</div>";

sunfighter
Feb 25th, 2012, 08:36 PM
What you have there is not what I told you to do!
If this html page is being loaded from another source it's that source that has to be changed.

free city
Feb 25th, 2012, 08:43 PM
I know that what I pasted should be the source code that generates the page

free city
Feb 25th, 2012, 08:44 PM
$descr1 is what brings the text in but how do I apply a size constraint to it

sunfighter
Feb 26th, 2012, 03:33 AM
What you have been giving us is PHP code:

<div style="width:800px;" >$descr1</div>";
$out.="<dd id=\"date\"><b>".__("Date listed")." :</b> $date</dd><div style="width:800px;" >$descr1</div>";
and
$descr1
I can not see that. Only you can. do you have to use the web site to trouble shoot or can you do it on your computer?

You need to find out exactly what $descr1 is.
You can add this line before the end of the web page. Find </body></html> near or at the end of your code and put this just before it:


<?php echo '<div style="border: red solid 1px;">'.$descr1.'</div>'; ?> You should see a red box with what $descr1 is, in it. Paste that here please. Of course I am assuming that the whole page is not generated with php.;)