Hi. I have found another peculiar situation. I added a banner that includes a source image to the show_all.html. Here is the file

<html>
<head>
<title>Erlang Web Shop - All Items</title>
<link rel="stylesheet" type="text/css" href="/style.css" />
</head>
<body>
<div id="banner">
Copyright &#169;2000 W.B.OTT. All rights reserved. Send mail to <a href="mailto:bill...@theotts.org";>bill...@theotts.org</a><br></br>
<img src="/cardfile.gif" ALIGN="Bottom" alt="The Ott's Web Site" />
</div>

<h1>All items that are stored in the shop:</h1>

<ul>
<wpart:list select="map" list="items" as="item">
<li>
<wpart:choose>
<wpart:when test="not {item:available}">
        NOT AVAILABLE
</wpart:when>
</wpart:choose>
<a wpart:href="/item/show/{[integer]item:id}"><wpart:lookup key="item:name" /></a>
</li>
</wpart:list>
</ul>
</body>
</html>

I also added a rule to the dispatch.conf. and placed the cardfile.gif in .../docroot/images/. I moved the lines around in dispatch.conf because I thought that maybe the static had to go first, but made no difference. Here is the dispatch code.

%%
%% ENTRIES FOR THE AUTOCOMPLETE WPART
%%
{static,"^/autocomplete.css$",enoent}.
{static,"^/jquery.autocomplete.js$",enoent}.
{static,"^/jquery.js$",enoent}.
{static, "^/images/.*\.gif$", enoent}.

%%
%% WELCOME PAGE
%%
{static,"^/?$","welcome.html"}.
{static, "^/style\.css$", enoent}.
%%
%% SHOP PAGES
%%
{dynamic, "^/item/all$", {browser, list_all}}.
{dynamic, "^/item/show/(?<id>[0-9]+)$", {browser, show_item}}.

{dynamic, delegate, "^/item/admin/", "config/dispatcher/admin.conf"}.
{dynamic, delegate, "^/user/", "config/dispatcher/user.conf"}.
{dynamic, "^/item/buy/(?<id>[0-9]+)$", {browser, buy_item}}.


%%
%% LOGIN URLs
%%
{static, "^/login", "login/login.html"}.
{dynamic, "^/do_login", {login, login}}.
{dynamic, "^/logout", {login, logout}}.

So the style sheet is working. the copyright is very small. The problem is the alt "The Ott's web" is shown (very small) instead of showing the image. Here is the generated xhtml.

<?xml version="1.0" encoding="utf-8"?>
<!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>
  <title>Erlang Web Shop - All Items</title>
        <link  rel="stylesheet"type="text/css"href="/style.css  
<view-source:http://localhost:8080/style.css>"/>
</head>
<body>
<div  id="banner">      
        Copyright ©2000 W.B.OTT. All rights reserved. Send mail to<a  
href="mailto:bill...@theotts.org";>bill...@theotts.org</a><br/>
  <img  src="/cardfile.gif  
<view-source:http://localhost:8080/cardfile.gif>"ALIGN="Bottom"alt="The Ott&apos;s Web 
Site"/>

</div>

  <h1>All items that are stored in the shop:</h1>

  <ul>

      <li>
        
        <a  href="/item/show/1  <view-source:http://localhost:8080/item/show/1>">Our 
first item</a>
      </li>

      <li>

        
        <a  href="/item/show/2  <view-source:http://localhost:8080/item/show/2>">Not 
out of stock item</a>
      </li>

      <li>
        
        <a  href="/item/show/3  
<view-source:http://localhost:8080/item/show/3>">Num3</a>
      </li>

      <li>
        
        <a  href="/item/show/7  
<view-source:http://localhost:8080/item/show/7>">another</a>

      </li>

      <li>
        
        <a  href="/item/show/6  <view-source:http://localhost:8080/item/show/6>">new 
part</a>
      </li>

  </ul>
</body>

Any help is appreciated....
</html>





--
Regards,
Bill Ott

Email: Mailto://bill...@theotts.org
Website: http://www.theotts.org

------------------------------------------------------------------------------
Let Crystal Reports handle the reporting - Free Crystal Reports 2008 30-Day 
trial. Simplify your report design, integration and deployment - and focus on 
what you do best, core application coding. Discover what's new with 
Crystal Reports now.  http://p.sf.net/sfu/bobj-july
_______________________________________________
Erlangweb-users mailing list
Erlangweb-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/erlangweb-users
http://www.erlang-web.org/

Reply via email to