detect IT
maybe you have the same problems to solve ... keep smiling ;)
Showing posts with label html. Show all posts
Showing posts with label html. Show all posts

Image representing Blogger as depicted in Crun...Image via CrunchBase

[edit]for an example you could have a look on my about me page[/edit]

Unfortunately it took a long time till i tried to simplify my former "how-to: Static Pages in Blogger ARE possible" [link], but here we go ...

I use the HTML/JavaScript widget to get the impression of static pages


Step 1: Layout -> Add a Gadget

Step 2: Basic -> HTML/JavaScript

Step 3: Add your static content and save

Step 4: Place it above the "Blog Posts"-Widget

Step 5: save your changes

now we have to hide this gadget (otherwise it would appear all the time before your blog actually starts - see screenshot below) – therefore we have to change the template (do yourself a favour and backup the template before you change something!!!)

Backup your template

Step 6: Activate the checkbox "Expand Widget Template"

Step 7: Search for the string “title='Blog Posts'” – that’s the first line of the post-widget
Your HTML/JavaScript widget should be direct above this widget

Step 8: To hide the widget we have to add a line of code

This way – you will only see the static content if you link to [YOURBLOG].blogspot.com/label/xxx

Step 9: To hide the Blog Posts while you are displaying the static content you have to add the following lines of code

Search for "id='nextprev'" and add the code directly under that line
Reblog this post [with Zemanta]


Read more...

 

This how-to is still "under construction" I just published it, because i think lots of people are suffering the same problem

[update]New Version available![/update]

Watch out my static 'About me' - page

'cause of a mysterious motivation boost i sat down yesterday night in front of my laptop, and tried to find is a way for "real-looking" static pages on blogspot.

and to make a long story short there is a way, to get professional looking static pages!

... i will still invest some work into this topic, but for now i will show you how it works with my 'quick-and-dirty' method (the breaking idea comes from hoctro's adding a frontpage tutorial).

here we go ...


1) let's start
add a page element (HTML/JavaScript) somewhere in the layout and drag it to show up before the 'blog post' section




2) change the layout
go to Layout - Edit HTML and enable the checkbox for Expand Widget Templates (do yourself a favour and SAVE your template before you change it)



3) search for the head-tag
and add the following lines of code directly after this tag





4) after the closing head-tag
you should find the body-tag - there you add onload='doIT()'




[body onload='doIT();']

5) now the magic happens!
search for your widget you added in step 1 (title) and add line 4 and 12




[b:widget id='HTML5' locked='false' title='About me' type='HTML']
[b:includable id='main']
[!-- static content starts--]
[b:if cond='data:blog.url == "http://[YOURBLOG].blogspot.com/search/label/xxx"']
[!-- only display title if it's non-empty --]
[b:if cond='data:title != ""']
[h2 class='title'][data:title/][/h2]
[/b:if]
[div class='widget-content']
[data:content/]
[/div]
[/b:if][!-- static content --]

6) we are nearly finished ...
search for widget blog1 and add lines 3 to 5




[b:widget id='Blog1' locked='true' title='Blog Posts' type='Blog']
[b:includable id='nextprev']
[b:if cond='data:blog.url != data:blog.homepageUrl']
[script]document.getElementById('Blog1').style.visibility='hidden';[/script]
[/b:if]

7) last one ...
edit your HTML/Javascript Widget you added in step 1
open the html view and add these lines






after that step, you can finally add your content!

So That's IT ... i know - it's not the easiest way, but i'm thinking of rewriting it to make it a bit easier. Maybe i even create a own widget to make it more comfortable to use


Reblog this post [with Zemanta]

Read more...

 

I searched for a simple script which validates a html-form and if everything is alright submit the form to a php script ... i didn't really find something so here is a simple one of mine

1st - create your form with the js-validation


onsubmit="return k_checkForm(this);"
method="post">
Name:
Number:



2nd - put a validation js somewhere in the html file (preferable in the head section)




3nd - php-script (server.php) here you can access the variables like this

echo $_POST["name"];
echo $_POST["phone"];

Read more...