[wp-hackers] Embedding forms in Wordpress

André Schieleit wphackerslist at anschitech.de
Fri Nov 10 23:35:30 GMT 2006


I want to use Wordpress as a cms for a website.
There will be posts and pages.
On one page I want to embedd a form where one can choose what will be  
shown on this page.
As a stand alone page on an other website this works just fine.
Embedded in Wordpress the initial page with the radio buttons and the  
select field will be shown correctly.
My problem is, that after pressing the submit button, the parameters  
appended to the url will not be recognized by the form. So the chosen  
data will not be displayed, just the initial page.
Additionally the layout is broken by this included page.

Here's the page: http://elektroink.de/transistoren/

Any hints how I can get this to work correctly?

Best Regards,
   André Schieleit

PS: Here's the code of my page.php:

<?php get_header(); ?>
<div id="content" class="narrowcolumn">

     <?php if (have_posts()) : while (have_posts()) : the_post(); ?>
	<div class="post" id="post-<?php the_ID(); ?>">
		<h2><?php the_title(); ?></h2>
             * if there is a directory "pages" in the home path of  
             * then look if there is a file with the name of the  
             * page and include it to this page.
             * this makes it possible to have a custom tailored page  
wich includes
             * php-code to have displayed within an existing wordpress
         <?php $page_include=ABSPATH."/pages/".get_the_title 
().".php"; ?>
         <?php if (file_exists($page_include)) :
		<div class="entrytext">
                 <?php the_content('<p class="serif">
                                         Lesen Sie den ganzen Beitrag  
                                    </p>'); ?>

                 <?php link_pages('<p><strong>Seiten:</strong> ', '</ 
p>', 'number'); ?>
       <?php endwhile; endif; ?>
     <?php edit_post_link('Diesen Beitrag bearbeiten.', '<p>', '</ 
p>'); ?>

<?php get_sidebar(); ?>
<?php get_footer(); ?>

More information about the wp-hackers mailing list