cool_slider - Version 0.0.2

Version Notes

rwd theme package files,, bug fixing

Download this release

Release Info

Developer Rehan Mobin
Extension cool_slider
Version 0.0.2
Comparing to
See all releases


Code changes from version 0.0.1 to 0.0.2

app/code/local/Tb/Coolslider/controllers/Adminhtml/SlideController.php CHANGED
@@ -78,7 +78,8 @@ class Tb_Coolslider_Adminhtml_SlideController extends
78
  public function saveAction(){
79
  if ($data = $this->getRequest()->getPost()) {
80
  if(isset($_FILES['image']['name']) && $_FILES['image']['name'] != '') {
81
- $imageRename = time().rand();
 
82
  try{
83
  $uploader = new Varien_File_Uploader('image');
84
  // Any of these extention would work
78
  public function saveAction(){
79
  if ($data = $this->getRequest()->getPost()) {
80
  if(isset($_FILES['image']['name']) && $_FILES['image']['name'] != '') {
81
+ $ext = pathinfo($_FILES['image']['name'], PATHINFO_EXTENSION);
82
+ $imageRename = time().rand().'.'.$ext;
83
  try{
84
  $uploader = new Varien_File_Uploader('image');
85
  // Any of these extention would work
app/code/local/Tb/Coolslider/etc/config.xml CHANGED
@@ -2,7 +2,7 @@
2
  <config>
3
  <modules>
4
  <Tb_Coolslider>
5
- <version>0.0.1</version>
6
  </Tb_Coolslider>
7
  </modules>
8
  <frontend>
2
  <config>
3
  <modules>
4
  <Tb_Coolslider>
5
+ <version>0.0.2</version>
6
  </Tb_Coolslider>
7
  </modules>
8
  <frontend>
app/code/local/Tb/Coolslider/sql/coolslider_setup/{mysql4-install-0.0.1.php → mysql4-install-0.0.2.php} RENAMED
File without changes
app/design/frontend/{default → base}/default/layout/coolslider.xml RENAMED
File without changes
app/design/frontend/{default → base}/default/template/coolslider/coolslider.phtml RENAMED
File without changes
app/design/frontend/rwd/default/layout/coolslider.xml ADDED
@@ -0,0 +1,20 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <layout version="0.1.0">
2
+ <default>
3
+ <reference name="head">
4
+ <action ifconfig="coolsliderset/general_settings/enable" method="addCss"><stylesheet>css/coolslider.css</stylesheet></action>
5
+ <action ifconfig="coolsliderset/general_settings/jquery_lib" method="addJs"><script>coolslider/jquery.min.js</script><params><![CDATA[name="cs_001"]]></params></action>
6
+ <action ifconfig="coolsliderset/general_settings/enable" method="addJs"><script>coolslider/jquery.nivo.slider.js</script><params><![CDATA[name="cs_002"]]></params></action>
7
+ </reference>
8
+
9
+ </default>
10
+
11
+
12
+ <superslider_index_index>
13
+ <reference name="root">
14
+ <action method="setTemplate"><template>page/1column.phtml</template>
15
+ </action>
16
+ </reference>
17
+ </superslider_index_index>
18
+
19
+ </layout>
20
+
app/design/frontend/rwd/default/template/coolslider/coolslider.phtml ADDED
@@ -0,0 +1,66 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ /**
3
+ * Tb_Coolslider
4
+ *
5
+ /****************************************************************************
6
+ * MAGENTO EDITION USAGE NOTICE *
7
+ ****************************************************************************/
8
+ /* This package designed for Magento Community edition. Author does not provide extension support in case of incorrect edition usage.
9
+ /****************************************************************************
10
+ * @category TB
11
+ * @package Tb_Coolslider
12
+ * @copyright Copyright (c) 2014
13
+ * @license http://opensource.org/licenses/OSL-3.0
14
+ */
15
+ /**
16
+ * coolslider template file
17
+ */
18
+ ?>
19
+
20
+ <?php
21
+ $settings = $this->getSettings();
22
+ $slideCollection = $this->getSlides();
23
+ $mediaUrl = Mage::getBaseUrl('media');
24
+ $count = 0;
25
+ ?>
26
+
27
+
28
+ <?php if(count($slideCollection)){ ?>
29
+ <div class="slider-wrapper" style="<?php echo 'width:'.$settings['width'].';height:'. $settings['height'] ?>;">
30
+ <div id="cool_slider" class="nivoSlider" style="height: <?php echo $settings['height']?>">
31
+ <?php foreach($slideCollection as $_slide){ ?>
32
+ <a href="<?php echo $_slide->getUrl()?$_slide->getUrl():'#'; ?>">
33
+ <img src="<?php echo $mediaUrl.$_slide->getImage()?>" alt="<?php echo $_slide->getTitle()?>" title="#htmlcontent<?php echo $count;?>" />
34
+ </a>
35
+ <?php $count++; } ?>
36
+ </div>
37
+ <?php $count = 0; // re-initialise $count ?>
38
+ <?php foreach($slideCollection as $_slide){ ?>
39
+ <div id="htmlcontent<?php echo $count;?>" class="nivo-html-caption">
40
+ <?php echo $_slide->getContents();?>
41
+ </div>
42
+ <?php $count++; } ?>
43
+ </div>
44
+
45
+ <?php } ?>
46
+
47
+ <script type="text/javascript">
48
+ jQuery.noConflict();
49
+ jQuery(document).ready(function() {
50
+ jQuery('#cool_slider').nivoSlider({
51
+ effect: '<?php echo $settings['effect'] ?>',
52
+ slices: <?php echo $settings['slices'] ?>,
53
+ boxCols: <?php echo $settings['boxCols'] ?>,
54
+ boxRows: <?php echo $settings['boxRows'] ?>,
55
+ animSpeed: <?php echo $settings['animSpeed'] ?>,
56
+ pauseTime: <?php echo $settings['pauseTime'] ?>,
57
+ manualAdvance: <?php echo $settings['manualAdvance'] ?>,
58
+ directionNav: <?php echo $settings['navigation'] ?>,
59
+ controlNav: <?php echo $settings['pagination'] ?>,
60
+ pauseOnHover: <?php echo $settings['pauseOnHover'] ?>
61
+ });
62
+ jQuery(".nivo-caption").css({
63
+ <?php echo $this->getContentPosition();?>
64
+ });
65
+ });
66
+ </script>
package.xml CHANGED
@@ -1,7 +1,7 @@
1
  <?xml version="1.0"?>
2
  <package>
3
  <name>cool_slider</name>
4
- <version>0.0.1</version>
5
  <stability>stable</stability>
6
  <license uri="http://opensource.org/licenses/osl-3.0.php">OSL</license>
7
  <channel>community</channel>
@@ -60,11 +60,11 @@ You can configure slider settings through various configuration options in admin
60
  &lt;h2&gt;Manage Slides&lt;/h2&gt;&#xD;
61
  After installing Cool slider entension you will find new item has been added to Admin navigation menu &#x201C;Cool Slider&#x201D; which as three sub-menu items -Add new slide-, -Manage Slides- and -Settings-&#xD;
62
  </description>
63
- <notes>Initial release.</notes>
64
  <authors><author><name>Rehan Mobin</name><user>rehanmobin</user><email>m.rehan.mobin@gmail.com</email></author></authors>
65
- <date>2014-05-15</date>
66
- <time>19:48:22</time>
67
- <contents><target name="magelocal"><dir name="Tb"><dir name="Coolslider"><dir><dir name="Adminhtml"><dir name="Model"><dir name="System"><dir name="Config"><dir name="Source"><file name="Directions.php" hash="f0101183c87dd3e4c4994465f1511770"/><file name="Effects.php" hash="80a8635dd7dc8d4eb2d1e7cbb9165cc3"/><file name="Positions.php" hash="c5233cf807e03fc89c0d416713285391"/></dir></dir></dir></dir></dir><dir name="Block"><dir name="Adminhtml"><dir name="Slider"><dir name="Edit"><file name="Form.php" hash="e6790fdc8a816d342f057afe5d6d05e7"/><dir name="Tab"><file name="Info.php" hash="8dd92266b086d2e201c1a2cc13591a31"/></dir><file name="Tabs.php" hash="a880e5f6f99815aa3e9c10078468a134"/></dir><file name="Edit.php" hash="f542381685d0e666d9d79b38a955ff14"/><file name="Grid.php" hash="88f5787ab3344dc9ce764b091bade7d5"/><dir name="Render"><file name="Image.php" hash="58c56beeed61b00fd1c226ea96acd088"/></dir></dir><file name="Slider.php" hash="053a3aa641ef23523144c4934d254bf5"/></dir><file name="Coolslider.php" hash="982c44f27662407e6ac1adf9550e8391"/></dir><dir name="Helper"><file name="Data.php" hash="4eca8676ee083c61eedc986b1c110928"/></dir><dir name="Model"><file name="Coolslider.php" hash="6b7bb889cd3b7712bc75a5f6b717d43f"/><dir name="Mysql4"><dir name="Coolslider"><file name="Collection.php" hash="e935f38bc057d958a19370c6c866cb8e"/></dir><file name="Coolslider.php" hash="e8a68ebb7bca7bb3e22f13b7b888660b"/></dir></dir><dir name="controllers"><dir name="Adminhtml"><file name="SlideController.php" hash="d03daf543b5031a1253c561bcbe69f08"/></dir><file name="IndexController.php" hash="a9a8e7e2d2a215eb793fad74c506fba4"/></dir><dir name="etc"><file name="adminhtml.xml" hash="30840537431498844fd8ee5f112803e0"/><file name="config.xml" hash="392b8fce14f5f63204cffb8537f94558"/><file name="system.xml" hash="a5b7443bb91ae9bfba60f4af5776a018"/></dir><dir name="sql"><dir name="coolslider_setup"><file name="mysql4-install-0.0.1.php" hash="0652a48e250d531fd4ffc22f6993d79d"/></dir></dir></dir></dir></dir></target><target name="mageetc"><dir name="modules"><file name="Tb_Coolslider.xml" hash="d9a94d000a34d847a944dafe0f090ac8"/></dir></target><target name="magedesign"><dir name="frontend"><dir name="default"><dir name="default"><dir name="layout"><file name="coolslider.xml" hash="77c3fddd6f0df78a9e3623317621797d"/></dir><dir name="template"><dir name="coolslider"><file name="coolslider.phtml" hash="98a3def3cd6489f0ab726949ca079559"/></dir></dir></dir></dir></dir><dir name="adminhtml"><dir name="default"><dir name="default"><dir name="layout"><file name="coolslider.xml" hash="f5ad3400209549f9256bcc46d7089e55"/></dir></dir></dir></dir></target><target name="mageskin"><dir name="frontend"><dir name="default"><dir name="default"><dir name="css"><file name="coolslider.css" hash="b3052cd0493c1aa66a3752ba4a4f9c1f"/></dir><dir name="images"><dir name="coolslider"><file name="left-arrow.png" hash="aa15f6f1accb60c4ed553708c14dbb34"/><file name="right-arrow.png" hash="b0797dd3cd1cf07d84d144a3b0c51fed"/></dir></dir></dir></dir></dir></target><target name="mage"><dir name="js"><dir name="coolslider"><file name="jquery.min.js" hash="2c57990a020cc3a35c4a603413d67a28"/><file name="jquery.nivo.slider.js" hash="bd3db6a383fe05a9ee9dcde94be9da1e"/></dir></dir></target></contents>
68
  <compatible/>
69
  <dependencies><required><php><min>5.2.0</min><max>6.0.0</max></php></required></dependencies>
70
  </package>
1
  <?xml version="1.0"?>
2
  <package>
3
  <name>cool_slider</name>
4
+ <version>0.0.2</version>
5
  <stability>stable</stability>
6
  <license uri="http://opensource.org/licenses/osl-3.0.php">OSL</license>
7
  <channel>community</channel>
60
  &lt;h2&gt;Manage Slides&lt;/h2&gt;&#xD;
61
  After installing Cool slider entension you will find new item has been added to Admin navigation menu &#x201C;Cool Slider&#x201D; which as three sub-menu items -Add new slide-, -Manage Slides- and -Settings-&#xD;
62
  </description>
63
+ <notes>rwd theme package files,, bug fixing</notes>
64
  <authors><author><name>Rehan Mobin</name><user>rehanmobin</user><email>m.rehan.mobin@gmail.com</email></author></authors>
65
+ <date>2015-01-27</date>
66
+ <time>18:52:18</time>
67
+ <contents><target name="magelocal"><dir name="Tb"><dir name="Coolslider"><dir><dir name="Adminhtml"><dir name="Model"><dir name="System"><dir name="Config"><dir name="Source"><file name="Directions.php" hash="f0101183c87dd3e4c4994465f1511770"/><file name="Effects.php" hash="80a8635dd7dc8d4eb2d1e7cbb9165cc3"/><file name="Positions.php" hash="c5233cf807e03fc89c0d416713285391"/></dir></dir></dir></dir></dir><dir name="Block"><dir name="Adminhtml"><dir name="Slider"><dir name="Edit"><file name="Form.php" hash="e6790fdc8a816d342f057afe5d6d05e7"/><dir name="Tab"><file name="Info.php" hash="8dd92266b086d2e201c1a2cc13591a31"/></dir><file name="Tabs.php" hash="a880e5f6f99815aa3e9c10078468a134"/></dir><file name="Edit.php" hash="f542381685d0e666d9d79b38a955ff14"/><file name="Grid.php" hash="88f5787ab3344dc9ce764b091bade7d5"/><dir name="Render"><file name="Image.php" hash="58c56beeed61b00fd1c226ea96acd088"/></dir></dir><file name="Slider.php" hash="053a3aa641ef23523144c4934d254bf5"/></dir><file name="Coolslider.php" hash="982c44f27662407e6ac1adf9550e8391"/></dir><dir name="Helper"><file name="Data.php" hash="4eca8676ee083c61eedc986b1c110928"/></dir><dir name="Model"><file name="Coolslider.php" hash="6b7bb889cd3b7712bc75a5f6b717d43f"/><dir name="Mysql4"><dir name="Coolslider"><file name="Collection.php" hash="e935f38bc057d958a19370c6c866cb8e"/></dir><file name="Coolslider.php" hash="e8a68ebb7bca7bb3e22f13b7b888660b"/></dir></dir><dir name="controllers"><dir name="Adminhtml"><file name="SlideController.php" hash="5728d9f215d0b0b226ceb0d8d0b7bdb0"/></dir><file name="IndexController.php" hash="a9a8e7e2d2a215eb793fad74c506fba4"/></dir><dir name="etc"><file name="adminhtml.xml" hash="30840537431498844fd8ee5f112803e0"/><file name="config.xml" hash="02473b48beea84b4442849e2a68e83ea"/><file name="system.xml" hash="a5b7443bb91ae9bfba60f4af5776a018"/></dir><dir name="sql"><dir name="coolslider_setup"><file name="mysql4-install-0.0.2.php" hash="0652a48e250d531fd4ffc22f6993d79d"/></dir></dir></dir></dir></dir></target><target name="mageetc"><dir name="modules"><file name="Tb_Coolslider.xml" hash="d9a94d000a34d847a944dafe0f090ac8"/></dir></target><target name="magedesign"><dir name="frontend"><dir name="base"><dir name="default"><dir name="layout"><file name="coolslider.xml" hash="77c3fddd6f0df78a9e3623317621797d"/></dir><dir name="template"><dir name="coolslider"><file name="coolslider.phtml" hash="98a3def3cd6489f0ab726949ca079559"/></dir></dir></dir></dir><dir name="rwd"><dir name="default"><dir name="template"><dir name="coolslider"><file name="coolslider.phtml" hash="98a3def3cd6489f0ab726949ca079559"/></dir></dir><dir name="layout"><file name="coolslider.xml" hash="dedc98a6aeba8374397f219b7ba285c5"/></dir></dir></dir></dir><dir name="adminhtml"><dir name="default"><dir name="default"><dir name="layout"><file name="coolslider.xml" hash="f5ad3400209549f9256bcc46d7089e55"/></dir></dir></dir></dir></target><target name="mageskin"><dir name="frontend"><dir name="base"><dir name="default"><dir name="css"><file name="coolslider.css" hash="b3052cd0493c1aa66a3752ba4a4f9c1f"/></dir><dir name="images"><dir name="coolslider"><file name="left-arrow.png" hash="aa15f6f1accb60c4ed553708c14dbb34"/><file name="right-arrow.png" hash="b0797dd3cd1cf07d84d144a3b0c51fed"/></dir></dir></dir></dir><dir name="rwd"><dir name="default"><dir name="css"><file name="coolslider.css" hash="b3052cd0493c1aa66a3752ba4a4f9c1f"/></dir><dir name="images"><dir name="coolslider"><file name="left-arrow.png" hash="aa15f6f1accb60c4ed553708c14dbb34"/><file name="right-arrow.png" hash="b0797dd3cd1cf07d84d144a3b0c51fed"/></dir></dir></dir></dir></dir></target><target name="mage"><dir name="js"><dir name="coolslider"><file name="jquery.min.js" hash="2c57990a020cc3a35c4a603413d67a28"/><file name="jquery.nivo.slider.js" hash="bd3db6a383fe05a9ee9dcde94be9da1e"/></dir></dir></target></contents>
68
  <compatible/>
69
  <dependencies><required><php><min>5.2.0</min><max>6.0.0</max></php></required></dependencies>
70
  </package>
skin/frontend/{default → base}/default/css/coolslider.css RENAMED
File without changes
skin/frontend/{default → base}/default/images/coolslider/left-arrow.png RENAMED
File without changes
skin/frontend/{default → base}/default/images/coolslider/right-arrow.png RENAMED
File without changes
skin/frontend/rwd/default/css/coolslider.css ADDED
@@ -0,0 +1,128 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ /* The Nivo Slider styles */
2
+ .slider-wrapper{
3
+ position: relative;
4
+ }
5
+
6
+ .nivoSlider {
7
+ position:relative;
8
+ width:100%;
9
+ height:auto;
10
+ overflow: hidden;
11
+ height: auto;
12
+ }
13
+ .nivoSlider img {
14
+ position:absolute;
15
+ top:0px;
16
+ left:0px;
17
+ max-width: none;
18
+ }
19
+ .nivo-main-image {
20
+ display: block !important;
21
+ position: relative !important;
22
+ width: 100% !important;
23
+ }
24
+
25
+ /* If an image is wrapped in a link */
26
+ .nivoSlider a.nivo-imageLink {
27
+ position:absolute;
28
+ top:0px;
29
+ left:0px;
30
+ width:100%;
31
+ height:100%;
32
+ border:0;
33
+ padding:0;
34
+ margin:0;
35
+ z-index:6;
36
+ display:none;
37
+ background:white;
38
+ filter:alpha(opacity=0);
39
+ opacity:0;
40
+ }
41
+ /* The slices and boxes in the Slider */
42
+ .nivo-slice {
43
+ display:block;
44
+ position:absolute;
45
+ z-index:5;
46
+ height:100%;
47
+ top:0;
48
+ }
49
+ .nivo-box {
50
+ display:block;
51
+ position:absolute;
52
+ z-index:5;
53
+ overflow:hidden;
54
+ }
55
+ .nivo-box img { display:block; }
56
+
57
+ /* Caption styles */
58
+ .nivo-caption {
59
+ position:absolute;
60
+
61
+ color:#fff;
62
+ width:100%;
63
+ z-index:8;
64
+ padding: 5px 10px;
65
+ overflow: hidden;
66
+ display: none;
67
+ -webkit-box-sizing: border-box; /* Safari/Chrome, other WebKit */
68
+ -moz-box-sizing: border-box; /* Firefox, other Gecko */
69
+ box-sizing: border-box; /* Opera/IE 8+ */
70
+ }
71
+ .nivo-caption p {
72
+ padding:5px;
73
+ margin:0;
74
+ }
75
+ .nivo-caption a {
76
+ display:inline !important;
77
+ }
78
+ .nivo-html-caption {
79
+ display:none;
80
+ }
81
+ /* Direction nav styles (e.g. Next & Prev) */
82
+ .nivo-directionNav a {
83
+ border-radius: 1px;
84
+ height: 52px;
85
+ margin-top: -26px;
86
+ opacity: 0;
87
+ position: absolute;
88
+ text-indent: -9999px;
89
+ top: 50%;
90
+ cursor: pointer;
91
+ width: 32px;
92
+ z-index: 6;
93
+ }
94
+ #cool_slider:hover .nivo-directionNav a {
95
+ opacity: 1;
96
+ }
97
+ a.nivo-prevNav {
98
+ background: url("../images/coolslider/left-arrow.png") no-repeat scroll 50% 50% #000000;
99
+ left: 0px;
100
+ }
101
+ a.nivo-nextNav {
102
+ background: url("../images/coolslider/right-arrow.png") no-repeat scroll 50% 50% #000000;
103
+ right: 0px;
104
+ }
105
+ /* Control nav styles (e.g. 1,2,3...) */
106
+ .nivo-controlNav {
107
+ bottom: 5px;
108
+ left: 50%;
109
+ margin: 0 auto;
110
+ position: absolute;
111
+ text-align: center;
112
+ width: auto;
113
+ z-index: 999;
114
+ }
115
+ .nivo-controlNav a {
116
+ background: none repeat scroll 0 0 #000000;
117
+ cursor: pointer;
118
+ float: left;
119
+ height: 10px;
120
+ border-radius: 1px;
121
+ margin: 0 0 0 10px;
122
+ text-indent: 9999px;
123
+ width: 10px;
124
+ }
125
+ .nivo-controlNav a.active {
126
+ background: none repeat scroll 0 0 #DBDBDB;
127
+ font-weight: bold;
128
+ }
skin/frontend/rwd/default/images/coolslider/left-arrow.png ADDED
Binary file
skin/frontend/rwd/default/images/coolslider/right-arrow.png ADDED
Binary file