World class Hard Drive Recovery and renowned raid recovery services

WestNIC provides reliable web hosting services

Site navigation below

This FAQ is part of the Code Style Help and FAQ section. Use the help request form below if your question is not answered here, but make sure you are asking the right question first.

Subscribe to this FAQ: RSS news feed

FAQ search

Help and FAQs

Q: What sort of questions are answered in your FAQs?

A: The level of questions addressed by our FAQs is exactly as published on the public FAQ pages, but subscribers get authenticated access to the full detail of premium content answers. The main criteria for answering questions is whether they are likely to be interesting and valuable to the majority of readers. See asking the right question for a guide to how we handle requests and Pending FAQ help requests for questions that are due to be answered.

Q: How do I access the premium content examples?

A: Subscribers to our premium content service get full access to all FAQ answers. Subscription costs $20 USD per year and includes email notificaton of all new answers. See our premium content service pagelink for full details and a subscription form. All payments are handled securely and independently by PayPal.

Q: How do I log in to the premium content area?

A: Where you see a premium content button, click the question link alongside to log in. This will open a log in dialogue box, where you enter your registered email address and the password you were sent when you subscribed. The illustrations below show each step.

Click the text link next to the premium content button

Click the text link next to the premium content button.

Type your registered email address and password in the login box

Type your registered email address and password in the login box.

Premium content page confirms you are logged in

Premium content page confirms you are logged in.

Q: How can I get a premium content subscription in India?

A: The PayPal site should include a currency conversion from US dollars to the primary currency of your PayPal account and tell you the amount that will be charged before you pay. When you create a PayPal account, you will be asked to choose a primary currency for the account. This is the currency in which the money in the account will be held. At present PayPal's primary currency options do not include Indian Rupees, so you will have to choose a different currency. If you choose United States dollars, for example, all funding payments to your PayPal account made in Rupees will be converted to US dollars.

Code Style questions

Q: Can I subscribe to this site?

A: There is no subscription service for the Code Style site as a whole. Each of the main articles has an email notification option at the end of the page. Whenever the article is updated, an email notification is sent to subscribers. There are also RSS news feeds for each of the FAQ sections.

Our premium content package is a paid subscription service that provides access to complete answers for all FAQ questions, The subscription provides a password log in to the questions marked with the premium content button.

Q: I can't get your code to work!

A: The Code Style Web site is not intended for absolute beginners and assumes readers have some grounding in the relevant technologies. Detailed help debugging the working examples on this site is not possible, there are so many things which could be wrong with an adapted version. However the following pointers should help you check the basics.

Is the external file reference correct?

The Code Style site uses relative URL paths with a leading forward slash, /; this means the URL is relative to the root level of the domain, not the current directory. If you are adapting Code Style examples on a local file system, you will need to change these file references accordingly.

The following examples use stylesheet references, but the same conditions apply to all external files including scripts and images.

./Style.css
Refers to the file Style.css in same directory as the HTML source, the "current" directory.
styles/Style.css
Refers to the file Style.css in a subdirectory of the current directory called styles.
../styles/Style.css
Refers to the file Style.css in a directory called styles at the same hierarchical level as the current directory, i.e. in parallel to it.

Has the script file loaded?

To check if an external script file has loaded, add the following code to the top of the file and reload the HTML:

// Debugging
alert('Script loaded.');
          

This should raise a visible dialogue box if the script loads (you may need to clear your browser's cache to force a reload). Once you're sure the script has loaded, put other temporary alerts into the script to find out which parts execute and which fail.

To check if an external stylesheet file has loaded, add an extreme style rule to make it obvious and reload the HTML:

BODY{
  color:            black;
  background:       red;
}
      

Remember, external stylesheets should not include any <style> markup or <!-- HTML "hiding" comments --> for the style rules.

If the CSS still isn't working, use a CSS syntax checker and markup validator to make sure you haven't corrupted the code in some way. Avoid the use of graphical HTML or CSS editors which may re-format or add to your code in unexpected ways. Microsoft Front Page is a frequent offender in this regard.

Site styling

Q: This site seems pretty plain, what's the problem?

A: The Code Style site uses Cascading Style Sheets (CSS) exclusively to suggest presentation styles for these Web pages, see Code Style CSS. If your browser doesn't support CSS, has CSS switched off, or has only rudimentary support for CSS, you will only experience these pages with whatever presentation settings your browser has configured.

The Code Style Web site is designed to work perfectly well without stylesheets, but see Style warning to find out how to enable CSS support in your browser or download a browser which supports CSS.

Finding content

Q: I couldn't find the site stylesheets, where are they?

A: All the stylesheets for the Code Style Web site are held in a separate directory from the XHTML documents. See Code Style CSS for full details.

Site styling

Q: Shouldn't you use a script to point users to browser friendly pages?

A: Hopefully you will see that all the pages on the Code Style site are browser friendly. The CSS style warning link is only to notify readers they are not be seeing the site in all its glory!

This site should work acceptably without CSS enabled, but readers' usability feedback is always welcome.

Q: Which heading font is used on the Code Style site?

A: The font specified for the headings is the generic font family serif, which means your browser should choose a font in that style, no particular font is named. Some browsers allow you to specify which serif font is used in this situation, the default may be Times or Times New Roman from Microsoft.

Help request

Use the form below to submit a help request or general enquiry about the Code Style Web site. Read our guidelines on asking the right questions first.

Information: Your email address will not be mis-used. If you include your address you may be sent a personal reply, you will not be added to any mailing list unless you request it. Read the site privacy statement for details.

Add this page to your chosen social bookmarking service

Style warning - please read

Home · CSS · Java · Javascript · HTML · Help · Log