RSS
 

Posts Tagged ‘Web’

Javascript: change img url and anchors title onclick

21 Aug

Recently, was playing around basic javascript Dom functionality elements. The main task was to trigger some functionality via onclick event of JS, and change the view of anchor and img tags inside the DOM component.

For instance we have HTML looking like this:

<a href="javascript:void(0)" onclick="enable_foo()" id="dist_link" title='Enable'><img src="ruler.png" id="ruler_img"/></a>

For this case a basic JS script would look like:

  function enable_foo(){
            var link_text =  document.getElementById('dist_link');
            var my_title = link_text.getAttribute('title');
 
            if(my_title == 'Enable'){
                link_text.firstChild.data = 'Disable';
                link_text.setAttribute('title','Disable');
                document.getElementById('ruler_img').src = "ruller_enabled.png";
            } else if(my_title == 'Disable'){
                link_text.firstChild.data = 'Enable';
                link_text.setAttribute('title','Enable');
                document.getElementById('ruler_img').src = "ruller.png";
            }

For avoiding the changes of the image, you can always fire up the title of anchor tag by removing the call for ‘ruler_img’ (with img tag inside anchor in HTML as well) tag and using:

       link_text.firstChild.data = 'Enable';
       //or
       link_text.firstChild.data = 'Disable';
 

Web.Outdated arguments

02 Nov

However, every time I surf through various popular sources, IT portals, and so forth, around 30% of the posts are just trolling on some outdated topics:

  • What’s the best Operating System?
  • What’s cooler: Windows/Mac vs. Linux?
  • China/Russia is an evil country: discussions about firewalls, rockets, nukes, and oil/democracy conflicts
  • Opera Browser is rubbish or why do you like Firefox so much? What about IE7?
  • Microsoft vs. Open-Source: they buy, we sell. Who’s true open-source and who’s not?!

So far, that’s what came to my mind. If you got other trolling topics to add, be my guest!

Updated:

  • Vi vs. Emacs: best editor? (updated by Leonid)
 

Twitter. Searching and bookmarking.

30 Oct

It’s time when I have to move from Del.icio.us and Google Bookmarks. Twitter Atom subscription gives quite good opportunity of tracking all the interesting things caught from Twitter on daily basis. A combination of GoogleReader and Twitter gives a nice service with:

  • Tags and categories can be made in GReader.
  • Accessing your bookmarks from phone by following Twitter updates.
  • Encapsulated Google Search in GReader won’t give a chance to miss any information once it was tracked through RSS/Atom feeds.
  • You can update your twits from phone/IM: fast and easy and clicking less.
 

Cross-browser apologies from j4vk.com

23 Oct

After adding Personalized Google search in the sidebar, I didn’t have a chance to test my blog template with all web browsers.

Thus, I make apologize to 24% of j4vk blog visitors using IE6, Google searchbar screwed up the sidebar layout (which you could have found at the bottom of the site).

Now everything seems to be fine in IE6, IE7, Firefox 2.0.0.8, and Safari 3.

 

Apple pages history

22 Jul

The appearance of new front page of Apple usually bring new vibes of design on the Web. Mac fans collected everything from 1997 year up to now.

 

Test your site for iPhone compatibility

28 Jun

iphoneyOn the 29th of June, Apple Inc. finally releases its phone, but you can already find some simulators for checking how your web apps will run on iPhone.

Marketcircle project offers iPhoney (so far for Macs) web simulator which you can find on SourceForge portal.

 

Design Roundup: 4th of April

04 Apr

Universe DailyLife – great Flash App covering the news, but in what matter!

StartDrawing.org – a portal brings you the works of talented Asian artists.

Stripe Generator – aren’t you get tired of drawing those patterns yourself?!

Shaded Borders with JavaScript – simple tutorial on JS shades usage.

 

CD’s, or Oslo Night sets loss!

26 Mar

Ronin Movie: Jean Reno photo5 years ago, or maybe six, I’ve been a big fan of djmixes2k portal, only because one show, which later on moved to Di.fm. It’s name is Oslo Nights. DJ’s from Norway, Sweden and the rest of North European countries used to spin their mixes up there.

It was in 2002 or in 2003, when Dj Elusive realised one of his first sets, and there was a tune from old (but gold!) movie “Ronin“, which plays during the story of 47 samurai’s who have become ronins. The original theme is gorgeous (Track #1), but what I’m looking for is its house remix.

The music those guys realised back in days, was the first step into progressive house: unbelievably melodic, at the same time it kept the rhythm and vibe of typical club electronic music: Dj Elusive, Likwit, Dj Stigma, Chloe Harris etc.

Surfing all other the Web, I could find only the history of Oslo Nights Shows, and supposedly, the track I’m looking for is:

Elusive (Dedicated to Morten RIP)

01 – Icehouse – Don’t Believe Anymore (Ivan Gough & Colin Snape remix)
02 – Jiva – Strange Dimensions (Original)
03 – Duran & Aytek – Elysium
04 – R. Carbonero feat Vicky – To Ermeticon (Lost Your God)
05 – Mansun – Wide Open Space
06 – Sigur Ros vs. Innerstate – Svefn G Englar (Floating 0angels)
07 – Tonuri – Take me (Elusive Edit)
08 – Duran & Aytek – Futurehope
09 – Descent – Round Midnight
10 – Deck Slaves – 47 Ronin
11 – White

But if someone saw this set somewhere in the web – paste me a link, and you’ll bright my day!..even though it’s night now! :)