Hi poojaindia. You mentioned creating a sidebar named “adsense” and using that in your code. Is “adsense” also the sidebar id? The unique sidebar id is the name you would use in your dynamic-sidebar code.
The css float style to display the “text-4” widget was based on the widget name created at runtime. An easier way to do it is to include the dynamic sidebar in a <div> container with a class, something like this:
<?php
echo '<div class="my-ad-sidebar">';
dynamic_sidebar('sidebar-id');
echo '</div>';
?>
Replace ‘sidebar-id’ with the id of your sidebar. Then the css would look like this:
.my-ad-sidebar {
float:left;
}
Let me know if you have any questions.
Thank you bdbrown. It was really helpful. Thanks again for sharing such great knowledge of yours. I request other users, who would be reading this query later for solutions to go through the link I mentioned in the first post. Then the solution would be clear. The problem has been resolved.