Support Forums for LiveMesh Themes & Plugins › Forums › Enticing Theme Support › Advertisement 125 Widget gives errors
Tagged: advertisement 125 widget
- This topic has 4 replies, 2 voices, and was last updated 8 years, 5 months ago by
livemesh.
-
AuthorPosts
-
August 22, 2012 at 9:48 am #265
tyrro
MemberHi,
I’m trying to use Advertisement 125 Widget but it’s giving me the following error after I move it to the sidebar widget area:
Warning: _() expects exactly 1 parameter, 2 given in /Applications/XAMPP/xamppfiles/htdocs/rocketplay/wp-content/themes/rocketplay/framework/widgets/mo-advertisement-125-widget.php on line 154
and this:
Warning: _() expects exactly 1 parameter, 2 given in /Applications/XAMPP/xamppfiles/htdocs/rocketplay/wp-content/themes/rocketplay/framework/widgets/mo-advertisement-125-widget.php on line 159
August 23, 2012 at 4:30 am #272livemesh
KeymasterIt is a bug that escaped us (probably since it is a warning). I think you are still able to specify the ads and display them. If not, can you pls make the following change to file
/Applications/XAMPP/xamppfiles/htdocs/rocketplay/wp-content/themes/rocketplay/framework/widgets/mo-advertisement-125-widget.php
by replacing the line numbers 153 to 161 with the below code?<p>
<label for="<?php echo $this->get_field_id($ad_link_id); ?>"><?php _e('Advertisement Link ', 'mo_theme') . $i; ?></label>
<input type="text" class="widefat" id="<?php echo $this->get_field_id($ad_link_id); ?>" name="<?php echo $this->get_field_name($ad_link_id); ?>" value="<?php echo $instance[$ad_link_id]; ?>" style="width:100%;" />
</p>
<p>
<label for="<?php echo $this->get_field_id($image_link_id); ?>"><?php _e('Image Link ', 'mo_theme') . $i; ?></label>
<input type="text" class="widefat" id="<?php echo $this->get_field_id($image_link_id); ?>" name="<?php echo $this->get_field_name($image_link_id); ?>" value="<?php echo $instance[$image_link_id]; ?>" />
</p>
I have this change taken care of in my update coming this week. Thanks
BTW, I am just replacing the
echo _('Advertisement Link ', 'mo_theme')
with_e('Advertisement Link ', 'mo_theme')
on line 154 and a similar change is being made on line 159 as well.August 23, 2012 at 5:20 am #275tyrro
MemberThanks, it’s working now.
August 23, 2012 at 5:44 am #276tyrro
MemberYou may also want to update line 31 of the same file and change the description of what this widget does 🙂
August 23, 2012 at 2:38 pm #279livemesh
KeymasterSure. Done. Thanks!
-
AuthorPosts
- You must be logged in to reply to this topic.