Support Forum

Please note that this forum is only available to you in read only mode. In order to contribute to this conversation you will need to renew your subscription.

Zenkit Blog template front end editing

zentoolsIf you use Zentools please post a review at the Joomla! Extensions Directory.

I want to have the "Item view options in category view" and "Item view options" to show in the Edit Item Front End popup window.
ScreenShot2012-09-28at09.35.59AM.png



I have tried to edit the statement in the itemform.php which hides the options when admins are on front-end. It starts in line 812.

I have not been able to get the view options to show on the font end.

Can you help me edit the /html/com_k2/templates/blog/itemform.php
  • ODiN Mayland's Avatar
  • ODiN Mayland
  • LIfetime Developer - Big Bamboo
  • 818 posts
  • 10 Thanks
  • Karma: 8
The administrator has disabled public write access.
Hi Jeff,

I'm not sure it's possible to do that actually - might be best to ask the folks at K2 if anyone has doen this before.

Thanks
  • Anthony Olsen's Avatar
  • Anthony Olsen
  • LIfetime Developer - Big Bamboo
  • 23925 posts
  • 788 Thanks
  • Karma: 433
The administrator has disabled public write access.
I did and someone said:

"
The check is the : <?php if($this->mainframe->isAdmin()): ?>

Of course you need to find where the if ends and remove the endif statement as well. If you are not familiar with this, ask a developer to do it for you."

LOL, so that's why I was posting it hear in case you could help :-)
  • ODiN Mayland's Avatar
  • ODiN Mayland
  • LIfetime Developer - Big Bamboo
  • 818 posts
  • 10 Thanks
  • Karma: 8
The administrator has disabled public write access.
Ok.

We would really just be doing it via trial and error or indenting the code if it needed it.

But I just had a quick look and it looks like it's the last endif before the closing form that matches the first if admin call.
  • Anthony Olsen's Avatar
  • Anthony Olsen
  • LIfetime Developer - Big Bamboo
  • 23925 posts
  • 788 Thanks
  • Karma: 433
The administrator has disabled public write access.
I removed the if/end for checking for admin but it still isn't working.
<h3><a href="#"><?php echo JText::_('K2_ITEM_VIEW_OPTIONS_IN_CATEGORY_LISTINGS'); ?></a></h3>
                                                                <div>
                                                                        <?php if(version_compare( JVERSION, '1.6.0', 'ge' )): ?>
                                                                        <fieldset class="panelform">
                                                                                <ul class="adminformlist">
                                                                                        <?php foreach($this->form->getFieldset('item-view-options-listings') as $field): ?>
                                                                                        <li>
                                                                                                <?php if($field->type=='header'): ?>
                                                                                                <div class="paramValueHeader"><?php echo $field->input; ?></div>
                                                                                                <?php elseif($field->type=='Spacer'): ?>
                                                                                                <div class="paramValueSpacer">&nbsp;</div>
                                                                                                <div class="clr"></div>
                                                                                                <?php else: ?>
                                                                                                <div class="paramLabel"><?php echo $field->label; ?></div>
                                                                                                <div class="paramValue"><?php echo $field->input; ?></div>
                                                                                                <div class="clr"></div>
                                                                                                <?php endif; ?>
                                                                                        </li>
                                                                                        <?php endforeach; ?>
                                                                                </ul>
                                                                        </fieldset>
                                                                        <?php else: ?>
                                                                        <?php echo $this->form->render('params', 'item-view-options-listings'); ?>
                                                                        <?php endif; ?>
                                                                </div>
                                                                <h3><a href="#"><?php echo JText::_('K2_ITEM_VIEW_OPTIONS'); ?></a></h3>
                                                                <div>
                                                                        <?php if(version_compare( JVERSION, '1.6.0', 'ge' )): ?>
                                                                        <fieldset class="panelform">
                                                                                <ul class="adminformlist">
                                                                                        <?php foreach($this->form->getFieldset('item-view-options') as $field): ?>
                                                                                        <li>
                                                                                                <?php if($field->type=='header'): ?>
                                                                                                <div class="paramValueHeader"><?php echo $field->input; ?></div>
                                                                                                <?php elseif($field->type=='Spacer'): ?>
                                                                                                <div class="paramValueSpacer">&nbsp;</div>
                                                                                                <div class="clr"></div>
                                                                                                <?php else: ?>
                                                                                                <div class="paramLabel"><?php echo $field->label; ?></div>
                                                                                                <div class="paramValue"><?php echo $field->input; ?></div>
                                                                                                <div class="clr"></div>
                                                                                                <?php endif; ?>
                                                                                        </li>
                                                                                        <?php endforeach; ?>
                                                                                </ul>
                                                                        </fieldset>
                                                                        <?php else: ?>
                                                                        <?php echo $this->form->render('params', 'item-view-options'); ?>
                                                                        <?php endif; ?>
                                                                </div>
  • ODiN Mayland's Avatar
  • ODiN Mayland
  • LIfetime Developer - Big Bamboo
  • 818 posts
  • 10 Thanks
  • Karma: 8
Last Edit: 12 years 3 weeks ago by ODiN Mayland.
The administrator has disabled public write access.
Hi,

I think this is really a little complex and beyond what we can help with here. The suggestion from above removes the admin check but there are likely to be a few more dependancies involved.

I agree with the K2 folks that you should contract a developer to help specifically with this sort of thing.

Let us know how you get on. Seems like a good idea but just not something we can help with at the moment.

Cheers Anthony
  • Anthony Olsen's Avatar
  • Anthony Olsen
  • LIfetime Developer - Big Bamboo
  • 23925 posts
  • 788 Thanks
  • Karma: 433
The administrator has disabled public write access.

zentoolsIf you use Zentools please post a review at the Joomla! Extensions Directory.

Happy Campers