• Resolved yourwp

    (@yourwp)


    Hello,

    is there more documentation(examples) available for themes?
    I need to add a description for each field.

    I see in the documentation i could use a theme, but when i add the imput outside the foreach, no much seems to happen. A field is added, but not used for calculation…

    Do you have a example where each field is added in the html instead of the foreach, so i could add descriptions in the html.

    tx

Viewing 6 replies - 1 through 6 (of 6 total)
  • Thread Starter yourwp

    (@yourwp)

    any news on this one?

    tx!!

    Thread Starter yourwp

    (@yourwp)

    Can someone please help me in the right direction?

    Is it even possible/clear what i try to do?

    This is getting a bit urgent.

    Plugin Author Altos

    (@sefin)

    Hi yourwp,

    you can find more documentation now here:
    https://woopricecalculator.com/documentation#customize-theme
    Hope this help you.

    If we managed to resolve your issue, please close this topic. Thank you.

    Regards,
    Simone

    Thread Starter yourwp

    (@yourwp)

    Dear Simone,

    tx for your reply!!!

    The fields are rendered correct. But they don’t work for the calculation.
    I can also enter text in a a number field. (Within the for each it worked)

    i added:

    <?php
    /*
     * THEME_NAME: Example (CUSTOM)
     */
    ?>
    
    <h1>This is a template example</h1>
    
    <div class="wpc-product-form">
    
        <?php
       echo $this->view['fields']['woo_price_calc_1']['label_name'];
    
        echo $this->view['fields']['woo_price_calc_1']['html'];
        echo $this->view['fields']['woo_price_calc_2']['label_name'];
    
        echo $this->view['fields']['woo_price_calc_2']['html'];
        
        echo $this->view['fields']['woo_price_calc_3']['label_name'];
    
        echo $this->view['fields']['woo_price_calc_3']['html'];
      
        echo $this->view['fields']['woo_price_calc_4']['label_name'];
    
        echo $this->view['fields']['woo_price_calc_4']['html'];
       
        echo $this->view['fields']['woo_price_calc_5']['label_name'];
    
        echo $this->view['fields']['woo_price_calc_5']['html'];
           echo $this->view['fields']['woo_price_calc_6']['label_name'];
    
        echo $this->view['fields']['woo_price_calc_6']['html'];
        ?>
    </div>
    
    

    tx !!!!

    Plugin Author Altos

    (@sefin)

    Hi, sorry I forgot some div in code, I’m going to update the documentation.
    Anyway here you can find the complete code for first 3 fields. It shouldn’t give you any issue.

    
    <?php
    /*
     * THEME_NAME: Example Simone
     */
    ?>
    
    <div class="wpc-product-form">
    	<!--Field start-->
    	<div id="<?php echo $this->view['data']['woo_price_calc_1']['elementId']; ?>" class="form-group wpc-field-widget">
    		<div class="wpc-field <?php echo $this->view['data']['woo_price_calc_1']['class']; ?>">
    		<?php echo $this->view['fields']['woo_price_calc_1']['html']; ?>
    		<label for="<?php echo $this->view['data']['woo_price_calc_1']['elementId']; ?>_field">
    			<?php echo $this->view['fields']['woo_price_calc_1']['label_name']; ?>
    		</label>
    		</div>
    		<div class="wpc-field-error"></div>
    	</div>
    	<!--Field end-->
    	<!--Field start-->
    	<div id="<?php echo $this->view['data']['woo_price_calc_2']['elementId']; ?>" class="form-group wpc-field-widget">
    		<div class="wpc-field <?php echo $this->view['data']['woo_price_calc_2']['class']; ?>">
    		<?php echo $this->view['fields']['woo_price_calc_2']['html']; ?>
    		<label for="<?php echo $this->view['data']['woo_price_calc_2']['elementId']; ?>_field">
    			<?php echo $this->view['fields']['woo_price_calc_2']['label_name']; ?>
    		</label>
    		</div>
    		<div class="wpc-field-error"></div>
    	</div>
    	<!--Field end-->
    	<!--Field start-->
    	<div id="<?php echo $this->view['data']['woo_price_calc_3']['elementId']; ?>" class="form-group wpc-field-widget">
    		<div class="wpc-field <?php echo $this->view['data']['woo_price_calc_3']['class']; ?>">
    		<?php echo $this->view['fields']['woo_price_calc_3']['html']; ?>
    		<label for="<?php echo $this->view['data']['woo_price_calc_3']['elementId']; ?>_field">
    			<?php echo $this->view['fields']['woo_price_calc_3']['label_name']; ?>
    		</label>
    		</div>
    		<div class="wpc-field-error"></div>
    	</div>
    	<!--Field end-->
    </div>
    

    If we managed to resolve your issue, please close this topic. Thank you.

    Regards,
    Simone

    • This reply was modified 7 years, 10 months ago by Altos.
    • This reply was modified 7 years, 10 months ago by Altos. Reason: typing errors
    Thread Starter yourwp

    (@yourwp)

    That works!! (dancing ;-))

    tx

Viewing 6 replies - 1 through 6 (of 6 total)
  • The topic ‘example theme’ is closed to new replies.