Skip to content

second batch of module tmpl codestyle#17852

Closed
zero-24 wants to merge 22 commits intojoomla:stagingfrom
zero-24:modules#2
Closed

second batch of module tmpl codestyle#17852
zero-24 wants to merge 22 commits intojoomla:stagingfrom
zero-24:modules#2

Conversation

@zero-24
Copy link
Copy Markdown
Contributor

@zero-24 zero-24 commented Sep 3, 2017

Summary of Changes

First batch of module tmpl codestyle

Testing Instructions

Please test and review the following frontend modules using the testing sampledata

  • mod_feed
  • mod_finder
  • mod_footer
  • mod_languages
  • mod_login

Expected result

Still works

Actual result

Works with codestyle problems

Documentation Changes Required

none

@zero-24 zero-24 changed the title seccond batch of module tmpl codestyle second batch of module tmpl codestyle Sep 3, 2017
<?php $lang = JFactory::getLanguage(); ?>
<?php $myrtl = $params->get('rssrtl'); ?>
<?php $direction = ' '; ?>
<?php $isRtl = $lang->isRtl(); ?>
Copy link
Copy Markdown
Contributor

@brianteeman brianteeman Sep 3, 2017

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Not sure why the first three lines above are aligned on the = but the line below is not?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

they was aligned because they where PHP only code i have reset the aligned. (comming with the next commit)

<?php endif; ?>
<?php if ($params->get('dropdown', 1) && !$params->get('dropdownimage', 0)) : ?>
<form name="lang" method="post" action="<?php echo htmlspecialchars(JUri::current(), ENT_COMPAT, 'UTF-8'); ?>">
<select class="inputbox advancedSelect" onchange="document.location.replace(this.value);" >
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

do we need the space before the > at the end?

<select class="inputbox advancedSelect" onchange="document.location.replace(this.value);" >
<select class="inputbox advancedSelect" onchange="document.location.replace(this.value);">
<?php foreach ($list as $language) : ?>
<option dir=<?php echo $language->rtl ? '"rtl"' : '"ltr"'; ?> value="<?php echo $language->link; ?>" <?php echo $language->active ? 'selected="selected"' : ''; ?>>
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Change to "<?php echo $language->rtl ? 'rtl' : 'ltr'; ?>"

<?php elseif ($myrtl == 0) : ?>
<?php $direction = ' redirect-ltr'; ?>
<?php elseif ($myrtl == 1): ?>
<?php $direction = ' redirect-ltr';?>
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Add space ?>

<select class="inputbox advancedSelect" onchange="document.location.replace(this.value);">
<?php foreach ($list as $language) : ?>
<option dir=<?php echo $language->rtl ? '"rtl"' : '"ltr"'; ?> value="<?php echo $language->link; ?>" <?php echo $language->active ? 'selected="selected"' : ''; ?>>
<option dir=<?php echo $language->rtl ? 'rtl' : 'ltr'; ?> value="<?php echo $language->link; ?>" <?php echo $language->active ? 'selected="selected"' : ''; ?>>
Copy link
Copy Markdown
Contributor

@Quy Quy Sep 3, 2017

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Missing beginning and ending "

<?php echo $output; ?>
<?php $show_advanced = $params->get('show_advanced'); ?>
<?php if ($show_advanced == 2) : ?>
<br />
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Multiple lines below.

<?php endif; ?>
<div id="form-login-submit" class="control-group">
<div class="controls">
<button type="submit" tabindex="0" name="Submit" class="btn btn-primary login-button"><?php echo JText::_('JLOGIN'); ?></button>
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Multiple lines

@Quy
Copy link
Copy Markdown
Contributor

Quy commented Sep 4, 2017

<?php endif; ?>
<?php // Feed image ?>
<?php if ($iUrl && $params->get('rssimage', 1)) : ?>
<img src="<?php echo $iUrl; ?>" alt="<?php echo @$iTitle; ?>"/>
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Add space before />

@@ -10,115 +10,80 @@
defined('_JEXEC') or die;
?>
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Add line before ?> and delete line after ?>.

<div class="input-prepend input-append">
<span class="add-on">
<span class="icon-star hasTooltip" title="<?php echo JText::_('JGLOBAL_SECRETKEY'); ?>">
</span>
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@@ -28,12 +28,16 @@
<div class="input-prepend">
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@Quy
Copy link
Copy Markdown
Contributor

Quy commented Sep 15, 2017

I have tested this item ✅ successfully on 6cbe566

Code review


This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/17852.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants