0

I want this two echo's to stay in one line. One in center and another right like I did but not in new line


echo "<a href=\"http://zafakultet.herobo.com\logout.php\"><font size=+1</font>Click here to logout!</a>"; echo "<p align=right>Username: " . $_SESSION["valid_user"];

I tried with <? ?> and it wont work.

Thanks for help.

3
Contributors
11
Replies
12
Views
5 Years
Discussion Span
Last Post by diafol
0

What are you trying to do?

PHP will spit out html. So if html will not produce a single line, you won't see a single line.

echo "<a href=\"http://zafakultet.herobo.com\logout.php\"><font size=+1</font>Click here to logout!</a>"; echo "<p align=right>Username: " . $_SESSION["valid_user"];

Will produce 2 lines - due to the <p> being a block element. You probably need to use a float in your css if you're determined to use this html syntax. Also close the <p> tag.

0

echo "<a href=\"http://zafakultet.herobo.com\logout.php\"><font size=+1</font>Click here to logout!</a>"; echo "Username: " . $_SESSION["valid_user"];

this will make look like this Click here to logout!username:.....

echo "<a href=\"http://zafakultet.herobo.com\logout.php\"><font size=+1</font>Click here to logout!</a>"; echo "<p align=right>Username: " . $_SESSION["valid_user"];

and this will make Click here to logout!
newline but right spot username:....

Edited by filipgothic: n/a

0

This is a CSS/HTML issue rather than PHP.

However,

echo "<p><a href=\"http://zafakultet.herobo.com\logout.php\"> Click here to logout {$_SESSION["valid_user"]}</a> </p>"

should work. But I'm still confused as to how you want this to look.

0

I want to have in middle option to logout and in same line but absolute right to show who is loged in and I might add more details later for now this only, you can look http://zafakultet.herobo.com user and pass 12345

Edited by filipgothic: n/a

0

This is a CSS/HTML issue rather than PHP.

I had a look at the link, no clues there. Couldn't log in with the details (user | 12345).

0

strange I tried with 12345 and pass 12345 is login every time, try again but nvm I want to have this two commands in same line seperated, how can seperate I heard there is some command &nbsp or something?

0

*stress* THIS IS CSS/HTML NOT PHP

BYE.

0

there is code to make space betwen text, if you do like 10x space it will still be one space but one simple code read full space.
bye

0

there is code to make space betwen text, if you do like 10x space it will still be one space but one simple code read full space.
bye

You don't mean the "code" &nbsp; do you? This will allow space between text..

0

hello again.
Read up on the following:
CSS attributes

display
float
position
padding

You DO NOT need to use &nbsp;

Edited by diafol: n/a

This topic has been dead for over six months. Start a new discussion instead.
Have something to contribute to this discussion? Please be thoughtful, detailed and courteous, and be sure to adhere to our posting rules.