Oh no! Where's the JavaScript?
Your Web browser does not have JavaScript enabled or does not support JavaScript. Please enable JavaScript on your Web browser to properly view this Web site, or upgrade to a Web browser that does support JavaScript.
Not a member yet? Click here to register.
Forgot Password?

Error while centering image in code

Asked Modified Viewed 746 times
V
Vyper69
V
Unprecedented Times call for Unprecedented Measures
  • Senior Member, joined since
  • Contributed 551 posts on the community forums.
  • Started 146 threads in the forums
  • Started this discussions
asked
Senior Member

Ok, so I am having trouble centering the image in this code.

echo "
<table width='100%' border='0' span style='color:#273B8D' cellpadding='0' cellspacing='0'>
<tr>
<td><img src='".THEMES."images/logo6.jpg' width='584' height='193' alt='' /></td>
</tr>
</table>
";


I have tried it multiple ways, but keep getting errors.
0 replies

4 posts

R
Anonymous User
R
Anonymous User 367
  • Veteran Member, joined since
  • Contributed 939 posts on the community forums.
  • Started 2 threads in the forums
  • Answered 20 questions
answered
Veteran Member

Why do you use tables? We are not in 2000 LOL.

https://www.w3schools.com/howto/howto_css_image_center.asp
1 reply
R
Anonymous User
R
Anonymous User 367
  • Veteran Member, joined since
  • Contributed 939 posts on the community forums.
  • Started 2 threads in the forums
  • Answered 20 questions
answered
Veteran Member

I'm sorry man, but I don't have time to write a code for you. You're still asking questions about CSS / HTML. I've sent you a link that contains exactly what you need.

Centering is really simple thing
<img src='....' style='display:block;margin: 0 auto;' class="img-responsive">


V8 have almost the same core as v7 so your old themes should still work.
1 reply
F
Falk
F
Falk 146
Need help?, Having trouble?
• View our Documentation for Guides, Standards and Functions
• Name and Organize your Topics and Content correctly in the corresponding Forums for best support results
• Attaching Log Files and Screenshots when reporting issues will help
• Provide with an URL to live example if one exists
• Please read the How to Report an Error post
• Please read and comply with the Code of Conduct

(¯·._.·(¯°·._.·°º*[ Project Manager ]*º°·._.·°¯)·._.·¯)
  • Super Admin, joined since
  • Contributed 6,201 posts on the community forums.
  • Started 639 threads in the forums
  • Answered 12 questions
answered
Super Admin

Quote

don't send me to some stupid tutorial, which explains nothing to me.


These tutorials show you exactly how it works and what to do if you take the time and follow it step by step.

If you do not want to follow tutorials and pointers I don´t see how you can achieve your goals?.
It is a learning experience to customize your site by your self and you need to do the learning.
It is unlikely that you will find someone to do all the work for you just for fun.
0 replies
C
Chan
C
Chan 0
Lead Developer of PHP-Fusion
  • Super Admin, joined since
  • Contributed 3,842 posts on the community forums.
  • Started 232 threads in the forums
  • Answered 6 questions
answered
Super Admin

Try this:


echo "<div class='display-block text-center'><img src='".THEMES."images/logo6.jpg' class='img-responsive' alt=''/></div>";


Read the helper css code in /templates/default.css, these rules are preloaded when you run v9 stock.

The latest v9 release uses Bootstrap 3.4 framework. Google that up, and play around with it for HTML/CSS work.
These are rules that are also preloaded to work with current theme, essentially cut down a lot of work necessary for the theme development. So the theme is dependent on the framework.

PHP and HTML are two separate matters. PHP is just altering conditions and provide source of data and view. HTML is basically what browser requires to draw up elements. Bootstrap 3.4 is a "theme for a theme" (boilerplate) to provide basic HTML UI for web interfaces. It has plugins and components you can use with just the CSS classes provided.
0 replies

Labels

None yet

Statistics

  • Views 0 views
  • Posts 4 posts
  • Votes 0 votes
  • Topic users 4 members

4 participants

F
F
Falk 146
Need help?, Having trouble?
• View our Documentation for Guides, Standards and Functions
• Name and Organize your Topics and Content correctly in the corresponding Forums for best support results
• Attaching Log Files and Screenshots when reporting issues will help
• Provide with an URL to live example if one exists
• Please read the How to Report an Error post
• Please read and comply with the Code of Conduct

(¯·._.·(¯°·._.·°º*[ Project Manager ]*º°·._.·°¯)·._.·¯)
  • Super Admin, joined since
  • Contributed 6,201 posts on the community forums.
  • Started 639 threads in the forums
  • Answered 12 questions
C
C
Chan 0
Lead Developer of PHP-Fusion
  • Super Admin, joined since
  • Contributed 3,842 posts on the community forums.
  • Started 232 threads in the forums
  • Answered 6 questions
V
V
Unprecedented Times call for Unprecedented Measures
  • Senior Member, joined since
  • Contributed 551 posts on the community forums.
  • Started 146 threads in the forums
  • Started this discussions
R
R
Anonymous User 367
  • Veteran Member, joined since
  • Contributed 939 posts on the community forums.
  • Started 2 threads in the forums
  • Answered 20 questions

Notifications

Track thread

You are not receiving notifications from this thread.

Related Questions

Not yet