Search Results

Search found 32871 results on 1315 pages for 'html attributes'.

Page 4/1315 | < Previous Page | 1 2 3 4 5 6 7 8 9 10 11 12  | Next Page >

  • Formatting HTML lists using CSS

    - by pwaring
    I'm trying to recreate list in HTML which has clauses and subclauses like this: 1. Main Clause (a) Sub clause (b) Sub clause 2. Another main clause (a) Sub clause The problems I'm running into are: If I use the existing HTML elements (ol and li) there doesn't seem to be a list style for (a) - I can have a. b. c. or A. B. C. but not (a) (b) (c). If I don't use the existing HTML elements and start using span tags, then if a subclause runs beyond the end of the line it appears underneath the clause number, rather than being indented. Like so: (a) Very long subclause which goes over one line when what I really want is the behaviour from lists, which is: (a) Very long subclause which goes over one line Is there any way to get round these two problems at the same time? I'd prefer to use semantic HTML and CSS for styling, but having the clauses spaced correctly is more important than doing things 'the right way'. I may need subsubclauses at some point (i.e. (i), (ii) etc.), so I can't assume that (a) will be the maximum clause depth.

    Read the article

  • Why is HTML/Javascript minification beneficial

    - by Channel72
    Why is HTML/Javascript minification beneficial when the HTTP protocol already supports gzip data compression? I realize that Javascript/HTML minification has the potential to significantly reduce the size of Javascript/HTML files by removing unnecessary whitespace, and perhaps renaming variables to a few letters each, but doesn't the LZW algorithm do especially well when there are many repeated characters (e.g. lots of whitespace?) I realize that some Javascript minification tools do more than just reduce size. Google's closure compiler, for example, also tries to improve code performance by inlining functions and doing other analyses. But the primary purpose of Javascript minification is usually to reduce file size. I also realize there are other reasons you might want to minify aside from performace, such as code obfuscation. But again, that reason is not usually emphasized as much as performance gain and file size reduction. For example, Closure Compiler is not advertised as an obfuscation tool, but as a code size reducer and download-speed enhancer. So, how much performance do you really gain from Javascript/HTML minification when you're already significantly reducing file size with gzip compression?

    Read the article

  • Html.LabelFor and Html.TextBoxFor generate empy html code

    - by Ceridan
    I'm writing my first ASP.NET MVC application and there is one big problem for me. I want to make a control which will represent a form, but when I try to generate labels and textboxes it returns to me empty page. So, this is my model file (MyModel.cs): namespace MyNamespace.Models { public class MyModel { [Required(ErrorMessage = "You have to fill this field")] [DisplayName("Input name")] public string Name{ get; set; } } } This is MyFormControlView.ascx file with my control: <%@ Control Language="C#" Inherits="System.Web.Mvc.ViewUserControl<MyNamespace.Models.MyModel>"%> <div> <% using (Html.BeginForm()) { Html.LabelFor(m => m.Name); Html.TextBoxFor(m => m.Name); Html.ValidationMessageFor(m => m.Name); } %> </div> And this is my Index.aspx file where I render the control: <%@ Page Language="C#" MasterPageFile="~/Views/Shared/Main.Master" Inherits="System.Web.Mvc.ViewPage<System.Collections.IEnumerable>" %> <asp:Content runat="server" ID="MainContent" ContentPlaceHolderID="MainContent"> This is my control test! <%Html.RenderPartial("MyFormControlView", new MyNamespace.Models.MyModel { Name = "MyTestName"}); %> </asp:Content> So, when I run my application the result is lonely caption: "This is my control test!" and there are no label or textbox on the generated page. If I inspect the source code of the generated page I can see my block, but it's inner text is empty. Please, could you help me?

    Read the article

  • Using embedded standard HTML forms with ASP.NET

    - by RM
    I have a standard aspx page with which I need to add another standard HTML form into and have it submit to another location (external site), however whenever I press the submit button the page seems to do a post back rather than using the sub-forms action url. A mock up of what the form relationships is below. Note in the real deployment the form will be part of a content area of a master page layout, so the form needs to submit independantly from the master page form. <html xmlns="http://www.w3.org/1999/xhtml" > <head runat="server"> <title>Untitled Page</title> </head> <body> <form id="form1" runat="server"> <div> <form id="subscribe_form" method="post" action="https://someothersite.com" name="em_subscribe_form" > <input type="text" id="field1" name="field1" /> <input id="submitsubform" type="submit" value="Submit" /> </form> </div> </form> </body> </html>

    Read the article

  • How do I extract HTML content using Regex in PHP

    - by gAMBOOKa
    I know, i know... regex is not the best way to extract HTML text. But I need to extract article text from a lot of pages, I can store regexes in the database for each website. I'm not sure how XML parsers would work with multiple websites. You'd need a separate function for each website. In any case, I don't know much about regexes, so bear with me. I've got an HTML page in a format similar to this <html> <head>...</head> <body> <div class=nav>...</div><p id="someshit" /> <div class=body>....</div> <div class=footer>...</div> </body> I need to extract the contents of the body class container. I tried this. $pattern = "/<div class=\"body\">\(.*?\)<\/div>/sui" $text = $htmlPageAsIs; if (preg_match($pattern, $text, $matches)) echo "MATCHED!"; else echo "Sorry gambooka, but your text is in another castle."; What am I doing wrong? My text ends up in another castle.

    Read the article

  • Jquery .html() function returns html out of nested order

    - by forcripesake
    I have a method which returns a persisted html template from a database. The template is of the format: <div id="item_collection"> <div id="item_x"> <p id="item_x_headline"><h2>Some Headline</h2></p> <p id="item_x_excerpt>Some text here</p> </div> <div id="item_x+1"> <p id="item_x+1_headline"><h1>Some Headline</h1></p> <p id="item_x+1_excerpt>Some text here</p> </div> ...and so on. </div> However after I run the following: alert(data); //check that the template is in order. It Is. $('#template_area').html(data); the Html is now: <div id="item_collection"> <div id="item_x"> <p id="item_x_headline"></p> <!--Note The Lack of Nesting --> <h2>Some Headline</h2> <p id="item_x_excerpt>Some text here</p> </div> <div id="item_x+1"> <p id="item_x+1_headline"></p> <!--Note The Lack of Nesting --> <h1>Some Headline</h1> <p id="item_x+1_excerpt>Some text here</p> </div> ...and so on. </div> So what gives? Is there a better way to replace the empty template_area's content than the .html() method?

    Read the article

  • Copying content on webpages in safari. To HTML

    - by Carl Smith
    Hi, is there an easier way to copy and paste website content in html? Want to copy and look like this. Product Information: Length: S / M / L Material: Polyester and Elasthane Brand: Roxana Exclusive Style: Basque But when i paste it into my content box it looks like this- Product Information Length: S / M / L Material: Polyester and Elasthane Brand: Roxana Exclusive Style: Basque Then i need to edit it in the html editor to rearrange it. Is the some sort of app or plugin that i can get so i can turn the text of the page into html so it looks right straight away when i copy it into my content box? If that makes any sense? Thanks Carl Smith :-)

    Read the article

  • Benefit of using Data URI to embed images within HTML document and its cross-browser compatibility

    - by Manoj Agarwal
    I want to embed an image using Data URI within HTML document so that we don't need image as a separate attachment, we get just one HTML file that contains the actual image. What are its advantages and disadvantages? Does IE10 supports it? Is it useful to have such an implementation? I am working on an application, where we have html documents that link towards images stored in some location. If I use tiny online editor, as images are saved somewhere in the server, while editing the document, i can provide a link towards that image, but can't preview the final document with images from within tiny editor. If I chose to download the file locally, then i will need to download the images from server side. It looks a bit overkill, so I thought if Data URI could be used in such a situation.

    Read the article

  • Why no client-side HTML include tag?

    - by Xepoch
    I had a question posed to me the other day by another programmer. I remember (a very long time ago) wondering the very same. Why was a browser-side include tag never considered? Or was it? Specifically with a tag that instructed the browser to include additional HTML from other sources. e.g. <include src="http://server/foo/bar.html">. Many folks will make javascript calls and fill innerHTML to accomplish the same, when the same outside a the javascript engine could be accomplished by the browser. It would have been painful to have nested <HTML>s <BODY>s (i.e.) but we have to consider that aspect anywhere anyway.

    Read the article

  • Joomla 1.5.26 won't let me insert html

    - by Arthur
    I am using the following code to try to embed chat in to an article in Joomla 1.5.26: <iframe src="http://xxxxxxx.com/welcome/visichat/" width="100%" height="550px" frameborder="0" scrolling="no"></iframe> Whenever I hit save, the code disappears. Actually, it seems that any html code I try to save disappears. I am trying with the toggle editor tab and the insert html button. Does anyone know why Joomla won't let me embed html? I am trying to get the chat to load with the site navigation still in place. I'd also be interested in hearing other ways to accomplish this.

    Read the article

  • Script to embed image and CSS data in HTML files

    - by andreas-h
    I have a HTML page which references external stylesheets and shows some images. I'm looking for an easy way to include all referenced external resources in the HTML file directly, so that it doesn't have any external references any more. (Images should be included in the HTML file using the <img src="data:image/jpg;base64,[...] method). EDIT: I want to do this so that my web proxy can deliver a nice-looking error page if the backend is down, so I have to assume all my webservers cannot deliver the static content which would normally be linked to from my websites (CSS, images).

    Read the article

  • I upgraded from win 7 to ubuntu 12.04 and know my html codes dont work

    - by user171010
    Hello i just started using Ubuntu the other day i never used Linux or anything else besides windows before. I started learning HTML on windows 7 before switching to Ubuntu and know my HTML images are not working even after i made new images on Ubuntu and put the correct path and made sure the images are .png. After all that the site does not load the new images and the coeds are just fine i put my HTML files on cloud storage before switching to Ubuntu so its not the codes. Also i am using Mozilla Fire Fox.

    Read the article

  • Beginning HTML and CSS [closed]

    - by romani
    My goal of learning HTML and CSS is to be able to modify popular scripts such as Wordpress, vBulletin, Drupal, etc. I haven't started yet learning CSS and HTML or XHTML. I see many, many books and tutorials out there so it is difficult to make a choice. I think most of web designers were like me in the past and have read many books. So, could you tell me about 1 good book for HTML and 1 good book for CSS? and if I should read the book from cover to cover or only learning the basics is enough for modifying Wordpress, for example!

    Read the article

  • Nicest way to map rgb colors from html to led

    - by back_ache
    I have attached an rgb led to a color picker on a webpage and have hit the obvious problem that though the led is 8-bit like html the color rendition is very different so with the more subtle shades the led values for the color are wildly different to the html values. The brute-force method would be for me to have a lookup-table on the webserver to map the two sets of values but would ideally like to do it more elegantly Before I start listing all my 101 ideas for doing this I wondered if anyone else had come across the issue, the end-game would be to be able to abstract the color-rendition of different leds and make it available as a webservice (html value and device id in, led value out)

    Read the article

  • Best practice for managing dynamic HTML modules?

    - by jt0dd
    I've been building web apps that add and remove lots of dynamic content and even structure within the page, and I'm not impressed by the method I'm using to do it. When I want to add a section or module into a position in the interface, I'm storing the html in the code, and I don't like that: if (rank == "moderator") { $("#header").append('<div class="mod_controls">' + // content, using + to implement line breaks '</div>'); } This seems like such a bad programming practice.. There must be a better way. I thought of building a function to convert a JSON structure to html, but it seems like overkill. For the functionality of the apps I'm using: Node.js JS JQuery AJAX Is there some common way to store HTML modules externally for AJAX importation?

    Read the article

  • HTML to XAML Conversion, Display HTML in RichTextBox

    - by Erika
    Hi, unfortunately im REALLY stuck on this and was wondering in anyone knows how to work around this. I have some html text which i want displayed in a WPF RichTextBox. At the moment, i'm using some helper APIs found http://blogs.msdn.com/wpfsdk/archive/2006/05/25/606317.aspx to convert HTML to XAML. So at the moment i have a xaml data string, but i cant see to find a way to display this correctly within the richtextbox :s i have been trying the following: string xamlData = HTMLConverter.HtmlToXamlConverter.ConvertHtmlToXaml(sBody,true); FlowDocument result = XamlReader.Load(new System.Xml.XmlTextReader(new StringReader(xamlData))) as FlowDocument; but this is crashing on the XamlReader.. Any other way will do, i just need to display an HTML string in this RichTextBox or something else! Please Help!

    Read the article

  • COMPLETE list of HTML tag attributes which have a URL value?

    - by system PAUSE
    Besides the following, are there any HTML tag attributes that have a URL as their value? href attribute on tags: <link>, <a>, <area> src attribute on tags: <img>, <iframe>, <frame>, <embed>, <script>, <input> action attribute on tags: <form> data attribute on tags: <object> Looking for tags in wide usage, including non-standard tags and old browsers as well as HTML 4.01, HTML 5, and XHTML. Yes this question is kinda lightweight, but I googled around for about 45 minutes and didn't find this data centralized anywhere, so I figure it might help some other developer to have it here. Plus I'm sure I'm missing something. Feel free to repeat/reorganize this list in your answer. Upvoting the most complete answers will probably be most helpful to others.

    Read the article

  • Html helper to show display name attribute without label

    - by Pedre
    I have this: [Display(Name = "Empresa")] public string Company{ get; set; } In my aspx I have: <th><%: Html.LabelFor(model => model.Company)%></th> And this generates: <th><label for="Company">Empresa</label></th> Are there any html helper extensions to only show the display attribute without label, only plain text? My desired output is this: <th>Empresa</th> Thanks! EDIT I tried DisplayFor or DisplayTextFor as suggested, but they are not valid because they generate: <th>Amazon</th> They return the value of the property... I want the name from the Display attribute.

    Read the article

  • Killing HTML nodes from shell

    - by hendry
    Need a solution to kill nodes like <footer>foobar</footer> and <div class="nav"></div> from many several HTML files. I want to dump a site to disk without the menus and footers and what not. Ideally I would accomplish this task using basic unix tools like sed. Since it's not XML I can't use xmlstarlet. Could anyone please suggest recipes, so I can ideally have a script running kill-node.sh 'div class="toplinks"' *.html to prune the bits I don't want. Thank you,

    Read the article

  • HTML encoding and decoding

    - by Zerotoinfinite
    Hi All, I am looking for a HTML editor, and I found many links through google like this http://online-html-editor.org/ Now I have written something on it: Let say the below content <div> <span style="font-weight: bold; font-size: 12pt; "> Heading</span></div> <div><br /> </div> The'la;skdlajlsdjansdkahskdkhaksdhkhaskdhkhaskhdkashdkhaksda <div>asdljalsjdljalsdjljalsdjljalsdjljalsdlajs;fl'ajduyasdahsldjkagsdhasvdjyhlasjdgklastgians,dkasjdlhakhsdl</div> <div>amsdka;sdlyasdalshdlj,asdh,asdjg,absdlasd/.malskdla'slduljds,vaskkd;jas;dl'asldu'alsdaskd;lk'as;d</div> <div>'a</div> <div>sd;jasldj;asdaklsdka'sld'sai'dkabskdm;;lsidaasfhdlasjd;ljaspodi;ajsd;lka'sld</div> <div>'</div> <div>ad'</div> <div>a;fj;ljas;dfjalshdoiauslkfdnkasfnlka's;dkap[sd'alsd;jlaksfdkajsdfh;alsd;</div> <div>asdkasjd;kaskd;as;dk;aksd;ajsdlkjalksjdlasjdkgasfkjashdjashdkasfdkjashkdasdjo[uipuhlkasdjlkajsdljalsjdlkajsdljaljsdljalsjdlkaslkjdlkasdjlasjdlkjaslkdjlasjdlasudqpeohw09iqwpekjqwehlj</div> <div><br /> </div> <div> <div> bool tt = new bool();</div> <div> if (txtStatus.Text == "true")</div> <div> tt = true;</div> <div> else</div> <div> tt = false;</div> <div><br /> </div> <div> </div></div> Now I want to save this content into the database and display as a normal text on a page. While extracting I can use Server.HTMLDecode, but I am facing problem while inserting this html data which I have copied from the sites. Please help. Thanks in advance.

    Read the article

  • HTMLAgilitypack getting <P> and <STRONG> text

    - by StealthRT
    Hey all i am looking for a way to get this HTML code: <DIV class=channel_row><SPAN class=channel> <DIV class=logo><IMG src='/images/channel_logos/WGNAMER.png'></DIV> <P><STRONG>2</STRONG><BR>WGNAMER </P></SPAN> using the HtmlAgilityPack. I have been trying this: With channel info!Logo = .SelectSingleNode(".//img").Attributes("src").Value info!Channel = .SelectSingleNode(".//span[@class='channel']").ChildNodes(1).ChildNodes(0).InnerText info!Station = .SelectSingleNode(".//span[@class='channel']").ChildNodes(1).ChildNodes(2).InnerText End With I can get the Logo but it comes up with a blank string for the Channel and for the Station it says Index was out of range. Must be non-negative and less than the size of the collection. I've tried all types of combinations: info!Station = .SelectSingleNode(".//span[@class='channel']").ChildNodes(1).ChildNodes(1).InnerText info!Station = .SelectSingleNode(".//span[@class='channel']").ChildNodes(1).ChildNodes(3).InnerText info!Station = .SelectSingleNode(".//span[@class='channel']").ChildNodes(0).ChildNodes(1).InnerText info!Station = .SelectSingleNode(".//span[@class='channel']").ChildNodes(0).ChildNodes(2).InnerText info!Station = .SelectSingleNode(".//span[@class='channel']").ChildNodes(0).ChildNodes(3).InnerText What do i need to do in order to correct this?

    Read the article

  • To HTML 5 or not HTML 5 ?

    - by ZX12R
    I am a designer whose main marketing strategy is multi browser compatibility. I assure my clients that the site will work even in IE6 (!). Of late i have been pondering over the question of moving to HTML 5. The reason behind my apprehension is that IE6 is still a major player in terms of market share and i don't want to lose it. Is there any way of moving to HTML 5 and still promise multi browser compatibility? Thank you.

    Read the article

  • Simple html vs Javascript generated html?

    - by Rizo
    In my web application I would like to complately avoid html and use only javascript to create web-page's dom tree. What is faster writing web content in the traditional way in html <div>Some text</div> or using javascript dom render, like this: div.appendChild(document.createTextNode("Some text"));?

    Read the article

< Previous Page | 1 2 3 4 5 6 7 8 9 10 11 12  | Next Page >