html

Extjs - Loading data to center region in border layout

I'm new to ExtJS and trying to experiment with the border layout. I can't seem to find a way to load ext components to the center region. Everything is contained in a viewport: new Ext.Viewport({ layout: 'border', items: [ I've set the west region with a treepanel as such: xtype: 'panel', region: 'west', width: 200, items: [...

Two level horizontal menu highlighting current page.

I've made a two level menu using CSS and HTML (ul's etc). What I want is the top level to be selected (using the 'selected' class) and the item in the second level that corresponds to the current page to have the class 'active' (which is just bold). EG when the user navigates to '/maintenance/company.aspx', I want the Maintenance menu i...

C++ Screen Scraping from HTML

Hi guys, i'm trying to extract the data "Lady Gaga Fame Monster" from the html below using substr and find, but i wasn't able to retrieve the data. <div class="album-name"><strong>Album</strong> > Lady Gaga Fame Monster</div> I'm tried to extract the whole string first, but i can only extract till Album under the command cout << line...

Rounded buttons breaks in chrome and safari

For creating rounded buttons, I am using three images a left image, a right image and a strip of image. Every where its working fine but in safari and chrome the right image comes in next line, and I am not able to understand why this is happening. So some one please help me , Here is the html markup and its css. <!DOCTYPE HTML PUBLIC "...

Wordpress get category main name

So if I'm on a subcategory page...how can I get the name of the main category? So let's say I'm on site.com /my-category/my-subcategory/ so how can I get "my-category" ? I don't want to parse the url :) cuz' I think wordpress has a built in function or smth. Best Regards, ...

How to trigger a select box to open when a link is pressed. (HTML/iPhone/Javascript)

Basically, I'm building a mobile site with LOTS of content. I have a header, then a menu with three buttons that I need to open select menus so that the iPhone's select wheel will appear. Any ideas? So far my searching says not possible... ...

IE6 Doesn't like my CSS :(

Web site: srstage.d19.us (sorry would only allow one link) How it looks in IE6: http://img94.imageshack.us/img94/4489/6c1bafd63a9d33b1231bd3d.png The 4 bugs are marked. no dotted border (on navigation and date badge) (from memory that isn't supported by IE6) sidebar mostly gone comment-meta is blank date badge is moved (positioning b...

Minimal Javascript to embed twitter feed into my html ?

What is the minimal Javascript to embed twitter feed into my html ? ...

Play MP3 in a loop with Mini MP3 Player

Hi, I am using a mini MP3 player to play an MP3 file. It is working fine, but I need to play the MP3 file in a loop. I have added a variable loop and set it to true but it still doesn't loop. <script type="text/javascript"> var so = new SWFObject("player.swf", "mp3player", "0", "0", "8", "#ffffff"); so.addVariable("file", "1-05_C...

Save textarea to MySQL and preserve line breaks

Imagine a blog or cms system (PHP and MySQL). I want to let the user enter some text in a textarea and save it to the database. The type of the field in the database is TEXT. I want to preserve line breaks and print them later. I know I can do this with PHP's nl2br-function, but how do I protect this string against SQL-injection attack...

Keyboard navigation using jQuery

Hello! I'm trying to add some keyboard support for a website I'm working on and I found these plugins for jQuery: shortKeys and jquery.hotkeys (can't post link because i'm a new user). The thing is I want to make it so that when a user presses "j", for example, to go to a different page, "about.html", for example, but, I don't know how t...

Is there a simpler option to "nest" or embed content without using iFrames or JavaScript to generate content?

I've read some related articles (like http://stackoverflow.com/questions/2907109/making-javascript-generated-content-possible-for-search-engines-to-index), but what I'd like to know, is there a simpler option to embed content from another site? Without the use of iFrames. What I'd like to achieve in the end is to create some sort of rep...

AIR application invocation from browser (HTML)

I am trying to launch my adobe AIR application from the browser. I have the following set: application.xml <allowBrowserInvocation>true</allowBrowserInvocation> AIR App <html> <head> <title>New Adobe AIR Project</title> <script type="text/javascript" src="lib/air/AIRAliases.js"></script> var globalinv...

What does square brackets in CSS class names means ?

I saw here square brackets that are used in class names: <input class="validate[required,custom[onlyLetter],length[0,100]]" name="firstname" type="text" /> What does this means ? ...

Toggle div containers of links using jQuery

I have a set of links and their corresponding divs showing information when clicked. What I want to do is using jQuery, when a link is clicked, the div of only that particular link should be shown, and the rest should hide. Right now, it displays all the div containers regardless of which link is clicked unless I click on the same link...

Aware of img tags with empty src in Chrome

Hello, As I figured out, Chrome do not ignore empty src, but loading currently viewed file into it. I had statistics counting error because of this "feature". Create file.php with this code... <? $fp = fopen("log", "a+"); fwrite($fp, time()."\"); fclose($fp); ?> <h1>Here is my page...</h1> <img src="" /> <img src="" /> ..and t...

Encoding problem: ("&amp;#163;") displaying instead of £.

I am accessing data from an SQLServer database to my ASP.Net C# based website. Now this data that i'm accessing is recieved from affiliate companies and it contains "& amp;#163;" (without quotes and space) for the £ sign. But when I'm displaying this data inside a label, instead of £ it shows "& #163;" (without quotes and space again ofc...

Is there any editor which supports html and jQuery code completion?

First of all, i use eclipse to edit my html files that's not weird at all. There are plugins for eclipse which supports html and jquery code completion. But eclipse takes too much memory of my system, and i want to get rid of eclipse for html editing. Now is there any free editor which supports html and jQuery code completion. No aptana ...

libxml2 HTML chunk parsing

I'm downloading HTML from a website. The file can be quite large so while the file's downloading, I want to already parse the available chunks of HTML so that the process appears faster for the end-user of my program. I don't have control over how the cunks are generated, so a chunk can begin in the middle of a word, e.g. like so: chunk...

Online WYSIWYG PDF editor

Hi, Actually i'm looking for a simple online WYSIWYG PDF editor where i can build simple formular (image,text,inputs) with drag&drop, but i could'nt find any. Alternatively i would also accept a HTML WYSIWYG editor like ckeditor, but with an Grid option for placing absolute elements. With only absolute elements it should'nt be hard to ...