Report Bugs Here

Moderator: Mmiscool

User avatar
By rwblinn
#49055 Hi,

uploaded w3.css using the file manager to /uploads/w3.css. Tried several options to change the style, but non worked.

Try 1
Code: Select allcss "w3.css"


Try 2
Code: Select allcss "/uploads/w3.css"


Try 3
Code: Select allwprint |<head>|
wprint |<title>ESP8266Basic HowTo - LED Toggle ON / OFF using w3.css</title>|
wprint |<link rel="stylesheet" href="http://www.w3schools.com/lib/w3.css">|   
wprint |<link rel="stylesheet" href="http://www.w3schools.com/lib/w3-theme-blue-grey.css">|
wprint |</head>|


Wanted to use the style, like
Code: Select allwprint |<header class="w3-container w3-theme w3-large w3-blue">|
wprint |ESP8266Basic HowTo - LED Toggle ON / OFF|
wprint |</header>|
wprint |<HR>|
wprint |<div class="w3-row-padding">|
wprint |<div class="w3-large w3-red">LED:|
textbox ledstatus
ledstatus = "OFF"
wprint |</div>|
User avatar
By Mmiscool
#49083 There seems to be some kind of problem righ now. If you right click and view source on the html that is out put from esp basic you will see the proper html code. It is kind of weird.
User avatar
By forlotto
#49310 Yes hopefully we figure that one out with bgcolor tables etc why it is not working in version 3 kind of makes me wonder.

I don't know if it is for everyone that it is not working or a select few that are missing something...

could it be something to do with graphics or websockets I see you are using iframes for graphics or so it seemed looking at the code briefly I may of had input output error while skimming lol ... I guess I would look at everything you updated recently and how it ties into the commands and eval etc... Maybe there is something not being sent that needs to be sent via html specification? A response a header something or something is being added that html does not like but not showing in the source. It is odd indeed.



I haven't yet tried 3.0 that much, been kind of tied up with other things and when I do get a little time I've been trying to answer questions if I can ...

Would be cool to bust this bug if it is not user initiated and can be reproduced.

As of right now I think v2.x branch still works fine so that is always an option for the time being.

EDIT UPDATE:

I dunno if I recall the file extension .css within the code I seen .pdf .zip .gzip etc I cannot recall the other names that were supported errrr....
Code: Select allString getContentType(String filename) {
  String ret = F("text/plain");
  if (filename.endsWith(".gz"))
  {
    ret = F("application/x-gzip");
    filename = filename.substring(0, filename.length()-3);
    Serial.println("getcontenttype " + filename);
  }
 
       if (filename.endsWith(".htm")) return F("text/html");
  else if (filename.endsWith(".html")) return F("text/html");
  else if (filename.endsWith(".htm")) return F("text/html");
  else if (filename.endsWith(".css")) return F("text/css");
  else if (filename.endsWith(".js")) return F("application/javascript");
  else if (filename.endsWith(".png")) return F("image/png");
  else if (filename.endsWith(".gif")) return F("image/gif");
  else if (filename.endsWith(".jpg")) return F("image/jpeg");
  else if (filename.endsWith(".ico")) return F("image/x-icon");
  else if (filename.endsWith(".xml")) return F("text/xml");
  else if (filename.endsWith(".pdf")) return F("application/x-pdf");
  else if (filename.endsWith(".zip")) return F("application/x-zip");
  else if (filename.endsWith(".gz")) return F("application/x-gzip");
return ret;


Hrmmm odd why do you have .htm listed twice???? This could be holding stuff up I would think maybe not but?