locked
Expression Web 3 Picture styles problem RRS feed

  • Question

  • Whenever I add styles to a picture in Expression Web 3 the software adds a slash to the path of the image so it no longer displays in the browser.  The original path reads src="assets/imagename.jpg" but after adding margins it now reads src="/assets/imagename.jpg.  I know I can go into the code and correct it but I am a college professor teaching this topic this fall and I will have 24 newbies in a lab all at once.  It will make my life a LOT easier if there is a universal fix to this error.  Thanks for your help.   SRC
    Thursday, August 9, 2012 3:38 PM

All replies

  • We can't fix the error - this isn't Microsoft you are talking to.  It's a user-to-user forum.

    But more to the point, is there really an error to fix?  What you describe simply doesn't happen to me.


    • Edited by KathyW2 Thursday, August 9, 2012 4:31 PM
    Thursday, August 9, 2012 4:30 PM
  • I realize you can't fix the error -- I was hoping someone could tell me some way to fix a setting somewhere.  It happens every time I add a picture and then add a style.  I add the picture, save it to a folder in my root directory and all is well.  Then, I add a style and the picture no longer appears in the browser.  While trying to figure out why this was happening I noticed that after I added the style there was suddenly an extra slash in the path in the HTML Code -- when I remove it the picture is visible in the browser once again.  I can alert my students to the possibility of this happening to them but if there is another solution that would be very helpful to me.

    SRC

    Thursday, August 9, 2012 4:46 PM
  • Are you adding an inline style or adding it to a css section in the page or external sheet?

    Like KathyW2, I can't duplicate it


    Expression Web MVP

    Thursday, August 9, 2012 5:31 PM
  • I am using the Appearance Tab on the Picture Properties dialog box.  I double click the picture and the Picture Properties dialog box opens. Using the Appearance tab I set the wrapping style and the margins. When I click OK Expression Web creates a new style and applies it to the <img> tag but it also adds that pesky slash. 

    I just created a page and added a picture -- here is the HTML

    <p>
    <img alt="Rain Forest Image" height="289" src="assets/RainForest.jpg" width="400" /></p>

    Now I've added alignment and margins -- here is the new code

    <p>
    <img alt="Rain Forest Image" class="style1" height="289" src="/assets/RainForest.jpg" width="400" /></p>

    The extra slash was added to the path.


    SRC

    Thursday, August 9, 2012 5:40 PM
  • That method creates auto-named styles, which is not the best way to go, but regardless: Nope, doesn't happen to me.

    I very much doubt anyone can help with the information you've provided.  Something else is going on outside the markup you've shown us.

    Thursday, August 9, 2012 5:48 PM
  • As I said earlier I am teaching this topic this fall and I am following the textbook which is what my students will be expected to do.  That is where this method came from.  Here is the code file -- all I've done is add a picture and then add margins and wrapping.  I am running Expression Web 3 on Windows 7 via Parallels 7 on Mac OS Lion.

    <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
    <html xmlns="http://www.w3.org/1999/xhtml">
    <head>
    <meta content="text/html; charset=utf-8" http-equiv="Content-Type" />
    <title>Untitled 1</title>
    <style type="text/css">
    .style1 {
        float: left;
        margin: 20px;
    }
    </style>
    </head>
    <body>
    <p>
    <img alt="Rain Forest Image" class="style1" height="289" src="/assets/RainForest.jpg" width="400" /></p>
    </body>
    </html>


    SRC

    Thursday, August 9, 2012 5:56 PM
  • That shows nothing that would explain what you see, so I'm not going to be able to help.

    Thursday, August 9, 2012 6:10 PM
  • That method creates auto-named styles, which is not the best way to go, but regardless: Nope, doesn't happen to me.

    I very much doubt anyone can help with the information you've provided.  Something else is going on outside the markup you've shown us.

    Actually, in my experiments, it created both an auto-style# and an inline style, the worst of all worlds. In practice, I would have created an appropriately named style, and applied that class to the elements which used it. If it was likely to be used in multiple pages, it would go in an external style sheet, not embedded in the <head> of one page.

    Regardless, as others have reported, following the steps you describe does not result in a leading slash in the src attribute on my machine, so what you are seeing is not standard behavior. Have you tried duplicating it on one of the student workstations to see if it is universal?

    cheers,
    scott


    Please remember to "Mark as Answer" the responses that resolved your issue. It is common courtesy to recognize those who have helped you, and it also makes it easier for visitors to find the resolution later.

    Thursday, August 9, 2012 6:25 PM
  • Hi Scott --

    I am currently working on my laptop at home but will be heading in to the computer lab to see if it will happen when the students try it.

    Later in the lessons they will create external style sheets -- this is just the beginning lesson on images.

    Thanks for trying,

    Susan


    SRC

    Thursday, August 9, 2012 6:32 PM
  • So....I guess it's my laptop configuration -- I tested it on my students' workstations and the issue does not arise.  Thanks to all who tried to help.

    SRC

    Thursday, August 9, 2012 8:26 PM
  • I've never seen that reported before. The only time I've seen file paths changed is when the person is NOT working in a defined local site.

    Why aren't you using EW 4 for your class? Academic Alliance users should have the latest version available as should students at accredited schools using Dreamspark software https://www.dreamspark.com/

    Expression Web 3 is rather outdated and anyone with a retail license of EW 3 received a free upgrade to EW 4 to encourage moving away from EW 3.


    Free Expression Web Tutorials
    For an Expression Web forum with without the posting issues try expressionwebforum.com

    Friday, August 10, 2012 3:33 PM
  • Susan,

    Just because the book shows that method doesn't mean you have to teach or encourage it. Many book promote bad habits before they teach best practices which means students have to unlearn what they've already learned. Sometimes it is kinder to yoru students not to follow exactly what is in the textbook. Teach best practices which is not to rely on those sorts of clicky, clicky methods that create bad code. Instead teach them how to create a new style using the New Style dialog box and that a meaningful name should always be used so that there is no confusion oven what the style does or should be used for. Creating the styles in the head section is fine whileworking on the page layout and design then moving them over to an external stylesheet later.

    I've done hands on labs for community college teachers and those who teach only what the books says in the order taught in the book are not producing students who can find employment on the web. You can't teach just how to use a specific program without teaching html & css along with best practices or you are wasting student's time and money. I run a 5,500+ mail list of Dreamweaver users and you should see what happens when someone comes from a class where they were taught only the point and click how to use the software approach in their web design classes. It isn't pretty and some of the method taught have resulted in some of the pros on the list and Adobe certified trainers sending letters to the college about the outdated and poor practices taught. I'm not saying that you are doing the same disservice to your students but it is something to be aware of.


    Free Expression Web Tutorials
    For an Expression Web forum with without the posting issues try expressionwebforum.com

    Friday, August 10, 2012 3:42 PM
  • When the department decided to teach this course in fall 2012 there were no textbooks for EW4 available. 

    SRC

    Friday, August 10, 2012 4:00 PM
  • I am well aware of your objections but these are not students who will be seeking employment in this field -- actually, these are students who aren't even interested in learning how to develop web pages -- this course is offered to help students fulfill a Math/CompSci general education requirement.  I will be teaching them HTML and CSS before we get to Expression Web and I do often skip chapters that encourage bad habits -- in this case I will be modifying the point and click lesson in the text to improve its value -- I ran into the issue because I am following the text (this is the first time I have taught this topic using these tools and books) in order to experience first hand the issues that might arise.

    SRC

    Friday, August 10, 2012 4:08 PM
  • It doesn't matter if you use an EW 3 book for EW 4. With the exception of the improved third party add-in support and the snippets panel that makes it easier to organize and use snippets the differences are under the hood. Think of EW 4 as what EW 3 was supposed to be but wasn't because it had to be released with the rest of the studio and wasn't fully finished at the Expression Studio 3 was launched. That's one reason why if you had purchased EW 3 at retail you received a free upgrade to EW 4 but if you had Blend or the full Studio you didn't get Blend 4 free. It was the major upgrade between v3 and v4. Use EW 4 in your class, it will be better for both you and the students, less bugs.


    Free Expression Web Tutorials
    For an Expression Web forum with without the posting issues try expressionwebforum.com

    Saturday, August 11, 2012 12:23 AM
  • Thanks for the advice -- I'll give it a try.  I still have a few weeks before classes start.

    SRC

    Saturday, August 11, 2012 1:14 AM