/    Sign up×
Community /Pin to ProfileBookmark

Any advice when combining php with css styling and divs

Hi there guys i am developing an site using both php and css.
My base for the design is a 960 grid system. with a style.css file for the design. and i am also using include files. My issue is as follows.
I have a navigation bar under the top banner some options in the navigation bar point to css elements# and they are easy to stye, and other options that dont point to any css #elements. They may point to some <?php ?>
like code in php for logging a user in log on or other phpcode.

Now to the facts when i am clicking the buttons on the navigation bar i see
a slight difference between in how the browser displays the page on my browser ( a slight difference in size ). What would be the best remedy for this ?
Can i get the php code within a div or some thing like that so that i can style it as for the the others, I am not an experienced developer so bare with me would you.

Note.
I dont use Dreamweaver or such, i just have a simple editor so i will have write it all.
I am on a linux and i need the php code for connecting and logging user on my database.
so far i have only one file for the css styling but i have several include files for php.

Thanks in advance guys….:rolleyes:

to post a comment
PHP

1 Comments(s)

Copy linkTweet thisAlerts:
@PlecPickerAug 07.2012 — I dont think i quite understand your question, a link to your site would help.

It sounds like you want to apply a style to a specific div that has already been styled?

most html tag will support a style attribute, and this will override and preset value.

in php you could echo out specific values easily

echo "<div style='width:".$Number."px;' >"; ....

Some browsers handle sizes differently, i make sure my images are the same size that i specify them to be.

Hope i understood you right.
×

Success!

Help @mrmagic spread the word by sharing this article on Twitter...

Tweet This
Sign in
Forgot password?
Sign in with TwitchSign in with GithubCreate Account
about: ({
version: 0.1.9 BETA 5.24,
whats_new: community page,
up_next: more Davinci•003 tasks,
coming_soon: events calendar,
social: @webDeveloperHQ
});

legal: ({
terms: of use,
privacy: policy
});
changelog: (
version: 0.1.9,
notes: added community page

version: 0.1.8,
notes: added Davinci•003

version: 0.1.7,
notes: upvote answers to bounties

version: 0.1.6,
notes: article editor refresh
)...
recent_tips: (
tipper: @AriseFacilitySolutions09,
tipped: article
amount: 1000 SATS,

tipper: @Yussuf4331,
tipped: article
amount: 1000 SATS,

tipper: @darkwebsites540,
tipped: article
amount: 10 SATS,
)...