Results 1 to 7 of 7
  1. #1
    Join Date
    Apr 2010
    Posts
    125
    Plugin Contributions
    0

    Default Targeting Tagless Text? with stylesheet

    Sorry if this is a stupid question but im just wondering if a can target text within a DIV that has no <p> tags or heading tags.

    for example, in my 'productDescription' DIV i have an image and text. to target the image i just put:

    #productDescription img {
    }
    but how would i target text in the same DIV?

    heres my website if this helps, http://www.clickpurchase.co.uk
    - The DIV im referring to is when you select a product, it has image and description.

    thanks in advance :)

  2. #2
    Join Date
    Aug 2005
    Location
    Arizona
    Posts
    27,755
    Plugin Contributions
    9

    Default Re: Targeting Tagless Text? with stylesheet

    You already have the div so just add any styling you desire like what I added in red or??
    Code:
    #productDescription {
    	margin-left: 50px;
            color: #ff0000;
            font-size: 1.5em;
            }
    Zen-Venom Get Bitten

  3. #3
    Join Date
    Apr 2010
    Posts
    125
    Plugin Contributions
    0

    Default Re: Targeting Tagless Text? with stylesheet

    Hi, thanks for the reply.

    This also effects the image in the same div, say for instance applying a background colour to the text, then the image also is given this background colour. I just want to apply it to the text within the DIV.

  4. #4
    Join Date
    Jul 2005
    Location
    Upstate NY
    Posts
    22,010
    Plugin Contributions
    25

    Default Re: Targeting Tagless Text? with stylesheet

    If you want to give a background to the text that doesn't include the image area, you will have to add <p>, <div>, <span> or other tags in the description. This is under user control, so what is the problem with doing this? If you are importing the description verbatim from a supplier, consider that your content is the same as everyone else who has the same product, and try adding something to make your content different/better.
    Also, if you use the product image feature in the info page, the image will be separate from the text, and automatically have an alt tag for search engine use.
    Last edited by gjh42; 18 May 2010 at 05:44 AM.

  5. #5
    Join Date
    May 2008
    Posts
    250
    Plugin Contributions
    1

    Default Re: Targeting Tagless Text? with stylesheet

    You should be able to do something similar to this:

    #productDescription {
    margin-left: 50px;
    background-color: #ff0000;
    }

    #productDescription img {
    background: none;
    }

  6. #6
    Join Date
    Apr 2010
    Posts
    125
    Plugin Contributions
    0

    Default Re: Targeting Tagless Text? with stylesheet

    Quote Originally Posted by gjh42 View Post
    If you want to give a background to the text that doesn't include the image area, you will have to add <p>, <div>, <span> or other tags in the description. This is under user control, so what is the problem with doing this? If you are importing the description verbatim from a supplier, consider that your content is the same as everyone else who has the same product, and try adding something to make your content different/better.
    Also, if you use the product image feature in the info page, the image will be separate from the text, and automatically have an alt tag for search engine use.
    Thanks, i will take all of that into consideration. The reason adding tags to the descreption is a problem is because id have to go back to all my current products individually adding the tags and this would be very time consuming. Although if theres no other way then i have no choice

  7. #7
    Join Date
    Jul 2005
    Location
    Upstate NY
    Posts
    22,010
    Plugin Contributions
    25

    Default Re: Targeting Tagless Text? with stylesheet

    Kerrin - The background would still surround the image even though it would not be behind it, as the image is inside the description div.

 

 

Similar Threads

  1. v154 Targeting customers
    By kalastaja in forum General Questions
    Replies: 7
    Last Post: 10 Mar 2016, 06:43 PM
  2. Targeting and Removing Subcategory text
    By creative in forum Templates, Stylesheets, Page Layout
    Replies: 1
    Last Post: 8 Sep 2008, 05:51 PM
  3. Email Targeting Customization
    By pheniks in forum General Questions
    Replies: 3
    Last Post: 18 Dec 2007, 09:12 PM
  4. Targeting certain information
    By brotherhud in forum Templates, Stylesheets, Page Layout
    Replies: 2
    Last Post: 19 Oct 2006, 01:03 AM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
disjunctive-egg