Copy link to clipboard
Copied
Hi:
I thought I was trying to do something very simple... add a space before the results {beds}.
I've tried margin-left, padding-left,   before {beds} but can't get it to move to the right a bit...
I think the PHP is messing with it, but not sure where to start.
<div class="group">
<div class="label"><label>Beds:</label></div>
<div class="field" style="width:435px; margin-top:-3px;">{beds}</div>
</div>
Thanks in advance 🙂 Jami
Copy link to clipboard
Copied
This is what it looks like currently, if this helps... I want more space btwn the field and the different kinds of beds.
Copy link to clipboard
Copied
You are posting to the wrong forum. Post in the Dreamweaver forum and include your CSS.
Copy link to clipboard
Copied
Oh sorry. I thought this was a PHP issue (Isn't that what the "{" signify?)
I needed to hunt down this code (which was hard, since I don't know much beyond basic html and css.)
I changed /"width:17px/" to /"width:13px/" and it worked. (I decided the boxes could be a bit less wide, and that resolved my other issue.
I don't know why it worked. But it did. Phew!
$bString = "";
$b = $this->getBeds(array("byRef" => true));
foreach($b as $bed){
$bString .= "
<div style=\"float:left;\">
<div style=\"float:left; width:35px;\">
<input type=\"text\" style=\"width:13px;\" name=\"bed-".$bed['id']."\" id=\"bed-".$bed['id']."\" value=\"".intval(@$beds[$bed['id']])."\" />
</div>
<div style=\"float:left; width:175px; padding-top:10px;\">
".urldecode($bed['bed_name'])."
</div>
</div>";
}
Copy link to clipboard
Copied
>Oh sorry. I thought this was a PHP issue (Isn't that what the "{" signify?)
Your html code IS contained in a php variable, but once the server is done with it the browser just see's html. So it's still a html rendering issue you are dealing with and these are better handled in the Dreamweaver forum. Glad you got it worked out though.
By the way, I would not hardcode the backslashes in your code as it makes it hard to maintain. If you need to add slashes, think about using addslashes() or a DBMS specific function if available.