Anpassa wordpress med reklam och liknande?

Permalänk
Medlem

Anpassa wordpress med reklam och liknande?

Hej!

Igår installerade jag wordpress på en sida, dock så vill jag justera den lite. Jag vill t.ex. ha lite reklam vid sidan, och kanske också ändra lite på designen. I och med att det är öppen källkod så borde det gå lätt att fixa.

Låt oss säga att jag vill ha en 100*100 px annons vid "sidebar". Jag har hittat lite text på wordpress hemsida där de förklarar hur man gör:

You can add ads to the sidebar by editing the sidebar.php template file. The standard WordPress sidebar template file features a complex nested list, so take care not to disturb the nest. You can carefully integrate ads into the list, or restructure the list to remove the nesting feature if the ad's code interupts the list format. Or add the ads to the top or bottom of the nested list, skipping any possible coding conflicts. To include the code inside of the list, you may need to put your advertisers code between a pair of <li> </li> tags or your page will not validate and may not look right. For example, you may want to include an ad between the Pages and Archives in your sidebar.

Jag förstår dock inte vad jag ska göra :/.

1. Är sidebar.php template file det samma som den som ligger någonstans i wordpress/wp-content?
2. Alltså, det jag ska göra är att lägga in <li> "annonskod" </li> där jag vill ha min ad. Koden jag hittade i sidebar.php är följande:

<?php
/**
* The Sidebar containing the primary and secondary widget areas.
*
* @package WordPress
* @subpackage Twenty_Ten
* @since Twenty Ten 1.0
*/
?>

<div id="primary" class="widget-area" role="complementary">
<ul class="xoxo">

<?php
/* When we call the dynamic_sidebar() function, it'll spit out
* the widgets for that widget area. If it instead returns false,
* then the sidebar simply doesn't exist, so we'll hard-code in
* some default sidebar stuff just in case.
*/
if ( ! dynamic_sidebar( 'primary-widget-area' ) ) : ?>

<li id="search" class="widget-container widget_search">
<?php get_search_form(); ?>
</li>

<li id="archives" class="widget-container">
<h3 class="widget-title"><?php _e( 'Archives', 'twentyten' ); ?></h3>
<ul>
<?php wp_get_archives( 'type=monthly' ); ?>
</ul>
</li>

<li id="meta" class="widget-container">
<h3 class="widget-title"><?php _e( 'Meta', 'twentyten' ); ?></h3>
<ul>
<?php wp_register(); ?>
<li><?php wp_loginout(); ?></li>
<?php wp_meta(); ?>
</ul>
</li>

<?php endif; // end primary widget area ?>
</ul>
</div><!-- #primary .widget-area -->

<?php
// A second sidebar for widgets, just because.
if ( is_active_sidebar( 'secondary-widget-area' ) ) : ?>

<div id="secondary" class="widget-area" role="complementary">
<ul class="xoxo">
<?php dynamic_sidebar( 'secondary-widget-area' ); ?>
</ul>
</div><!-- #secondary .widget-area -->

<?php endif; ?>

Vad ska jag lägga in min <li> "annonskod" </li> om jag vill ha annonsen högst upp i sidebaren?

Tack på förhand!

Permalänk
Medlem

Jag kan tillägga att det jag har nu i sidebaren som de liknar med "pages" och "archives" är recent entry, category och links.

Permalänk