1 year ago
That code would go at the end of the header.php (of the template)
<div id="navbarright">
<form action="http://www.kaosklub.com" id="searchform">
<input type="hidden" name="cx" value="partner-pub-8683538658017137:5acdqp-99t9" />
<input type="hidden" name="cof" value="FORID:11" />
<input type="hidden" name="ie" value="ISO-8859-1" />
<input type="text" value="" name="q" size="15" id="searchbox" onfocus="if (this.value == 'Buscar...') {this.value = '';}" onblur="if (this.value == '') {this.value = 'Buscar...';}" />
<input type="submit" name="sa" id="searchbutton" value="OK" />
</form>
</div>
</div>
<div id="wrap">
<div align="center" id="cse-search-results" align="justify"></div>
<script type="text/javascript">
var googleSearchIframeName = "cse-search-results";
var googleSearchFormName = "cse-search-box";
var googleSearchFrameWidth = 850;
var googleSearchDomain = "www.google.es";
var googleSearchPath = "/cse";
</script>
<script type="text/javascript" src="http://www.google.com/afsonline/show_afs_search.js"></script>
Paste this in your website: <script type="text/javascript" src="http://www.posteet.com/embed/1581"></script>
1 year ago
Original web not working, here's the code
<?php
/*
Plugin Name: Limit Posts
Plugin URI: http://labitacora.net/comunBlog/limit-post.phps
Description: Limits the displayed text length on the index page entries and generates a link to a page to read the full content if its bigger than the selected maximum length.
Usage: the_content_limit($max_charaters, $more_link)
Version: 1.1
Author: Alfonso Sánchez-Paus Díaz y Julián Simón de Castro
Author URI: http://labitacora.net/
License: GPL
Download URL: http://labitacora.net/comunBlog/limit-post.phps
Make:
In file index.php
replace the_content()
with the_content_limit(1000, "more")
*/
function the_content_limit($max_char, $more_link_text = '(more...)', $stripteaser = 0, $more_file = '') {
$content = get_the_content($more_link_text, $stripteaser, $more_file);
$content = apply_filters('the_content', $content);
}
else if ((strlen($content)>
$max_char) &&
($espacio =
strpos($content,
" ",
$max_char ))) {
$content =
substr($content,
0,
$espacio);
$content = $content;
}
else {
}
}
?>
Paste this in your website: <script type="text/javascript" src="http://www.posteet.com/embed/1579"></script>