user123
user123

Reputation: 5407

Including content of php page into another

I know what to use and how. Here is my script:

<html>
<body>

<div style="top:230px; right:50px">  // Style does not work
<?php include 'index.php'; ?>
</div>

<h1>Welcome to my home page.</h1>
<p>Some text.</p>

</body>
</html>

index.php contains this page:

http://yepinol.com/wall/

I want to place this content as specifi height, and location on the page. For that I added style as above. But it's height and left right position does not change?

Why? index.php - source code of index.php

Upvotes: 0

Views: 41

Answers (1)

Sudhir Bastakoti
Sudhir Bastakoti

Reputation: 100175

for top css attribute you need to add position. It has no effect on non-positioned elements.So do, like:

position: relative;

Upvotes: 3

Related Questions