html

regex problem in php

<div class="begin">...</div> How to match the html inside(including) <div class="begin"> in PHP? I need a regex solution that can handle nested case. ...

Is it possible to 'store search criteria' and the reuse it at some other time?

I have a classifieds website where users may search ads. I wonder if I can somehow store search criteria and whenever the users wishes, reuse that search criteria to make another search again, exactly the same... ? This would make it easier for users to search for a specific car for instance, and not have to fill in all the details suc...

which tag to use if i want to select an option from dropdown as wel as i can insert my own option.

which tag to use if i want to select an option from dropdown as wel as i can insert my own option. so using jsp can i do it? i m able to fetch the complete list to serve as option but i want to insert my own option as wel. what is the convenient technique using jsp? i mean like the way we insert into text box. i have seen in some sites ...

return html from wcf service

Hello, I have a web service from which I need to return a string containing html. This html is the markup for a Select control (for use in jqGrid search filters), e.g. <select><option id='1'> value 1 </option></select> My WCF web service contains a method that returns this value as a string... public string GetLeadTypeSelec...

How to store search criteria or search results?

I have a php classifieds website (mostly) and I am currently using MYSQL as a database. Later on I will use SOLR or maybe Sphinx as a "search engine". I want to make it possible for users to view "results" of searches they have made before, but I don't know where to start... How is this done? Currently I have a form which is filled i...

can i insert my own option in select tag

which tag to use if i want to select an option from dropdown as wel as i can insert my own option. using jsp can i do it? i m able to fetch the complete list to serve as option but i want to insert my own option as wel. what is the convenient technique using jsp? i mean like the way we insert into text box. i have seen in some sites tha...

How can I send a big HTML block in JSON

I need to send a big block of HTML in a Json object like this: JsonResult jsn = Json(new Dictionary<string, object> { { "success", true }, { "lastPID", posts[0].ID }, { "content", "" } }); return jsn; For some reason I get this error when I put that html block into the content var...

how to remove tags with JavaScript regular expressions

I have a JavaScript string containing HTML like this: <div> <div class="a"> content1 </div> content 2 <div class="a"> <b>content 3</b> </div> </div> and I want to remove the div's of class="a" but leave their content. In Python I would use something like: re.compile('<div class="a">(.*?)</div>', re.DOTALL).sub(r'\1', html) ...

WYSIWYG html editor query.

I am in the process of creating a simple WYSIWYG html editor to enable the users of my application to design simple html emails. At the moment I have decided to use the web browser control with mshtml to enable me to edit what is displayed. I have a tool bar which holds all of the relevant buttons (bold, underline, etc.). I need a way ...

IE6+7 showing problems with an ordered list

IE6 and 7 seem to like to push the list left, and cut off the numbers at www.qwibbledesigns.co.uk/preview/aurelius/about.html , near the bottom. Does anyone know whats going on? ...

Drupal + LightBox2 component = use body as title (caption) for lightbox

Hi there I am using the LightBox2 component on my website to display the gallery images in a grouped lightbox. I add images to the website by using the Image component and adding all the images to the Photos book. However, images can still be viewed separately on a page, if I so choose. The url would then look something like this: www.m...

Not able to set border for DIV

Below is my code. I have defined border style, still when the page renders, it disappears in some browsers. How to set the border? <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"&gt; <html xmlns="http://www.w3.org/1999/xhtml"&gt; <head> <meta http-equiv="Content-Ty...

JEditorPane do not respect html table height 100%

Hi Stackoverflow, i have got a problem, my JEditorPane do not respect HTML-Table style="height: 100%;" do you have an idea? JEditorPane jEditorPane = new JEditorPane(); JScrollPane scrollPane = new JScrollPane( jEditorPane ); jEditorPane.setPage( url ); JFrame frame = new JFrame( ); frame.getContentPane( ).add( scrollPane, BorderLayou...

HTML Background Image Map

Is it possible to create an image map from a background image? I'd like to have the sides of the screen clickable and I do not see any way to accomplish this without a map. ...

Any way to gracefully enforce a timeout limit when loading a slow external file via javascript?

I'm using javascript to include some content served up from a php file on another server. However, this other service can sometimes get flaky and either take a long time to load or will not load at all. Is there a way in JS to try to get the external data for x number of seconds before failing and displaying a "please try again" messag...

CSS container doesn't stretch to accomodate floats

<html> <head> <style type="text/css"> .container { width: 900px; border: 2px solid #333333; padding-top: 30px; padding-bottom: 30px; } .container_left { border: 2px solid #FF00FF; width: 650px; float: left; } .container_right { border: 2px solid #0000FF; width: 225px; ...

Link with Name Attibute in Rails

I was wondering about how i can do this in rails because i want something like <a href="requests/13#new">Comment!<a> anyone knows it? greetings ...

Any advice for developing for Chrome?

I have a site that I used making CSS,HTML,javascript,Jquery,and PHP. I have made it work on all known browers (IE,FireFox,Safari,ETC...) All of a sudden chrome came out and I looked and my site is jacked. I know this is not a very detailed question but I am just looking for a little guidance for any resources,tips,suggestions on how to...

Cannot prettify scraped html in BeautifulSoup

I have a small script that use urllib2 to get the contents of a site, find all the link tags, appends a small piece of HTML in on the top and bottom, and then I try to prettify it. It keeps returning TypeError: sequence item 1: expected string, Tag found. I have looked around, can't really find the issue. As always, any help, much apprec...

Web scraping etiquette

I'm considering writing a simple web scraping application to extract information from a website that does not seem to specifically prohibit this. I've checked for other alternatives (eg RSS, web service) to get this information, but there are none available at this stage. Despite this I've also developed/maintained a few websites mys...