Oh no! Where's the JavaScript?
Your Web browser does not have JavaScript enabled or does not support JavaScript. Please enable JavaScript on your Web browser to properly view this Web site, or upgrade to a Web browser that does support JavaScript.
Sign In
Not a member yet? Click here to register.

Orbit Panel

www.php-fusion.co.uk/infusions/marketplace/uploads/image/t_1007.pngThe central panel slide show of photos from the past 10 to your gallery.

Note: all photos in the gallery must be greater than 700 x 350 pixels, otherwise the quality will be poor.



-- View this Addon --
Good Work... ;) Keep Sharing all Good Addons with PHP-Fusion community :)
Once more again: Well done!
@Ankur, Ypsilon, thanks guys!
:)
Great work jikaka,you are super www.hayaletsevgili.com/images/smiley/tup.gif
@HaYaLeT, you flatter me...
:D
Not flatter :D it is really..
This panel could be modified to show the news images from news of a certain category, and linking to that news item, no?

I'll try it myself, but I'm not very good at SQL Queries and PHP... But i'll try.
Thanks jikaka :D
@Kevin Maschke, you can try
@Craig, thanks
HI!

I've been trying a little bit... But I get an nasty error. I use:

[syntaxhighlighter brush=sql,first-line=1,highlight=0,collapse=false,html-script=false]
$result=dbquery(
"SELECT * FROM ".$db_prefix."news
WHERE news_id=".$info['news_id']." AND news_cat=11"
);
[/syntaxhighlighter]

And:

[syntaxhighlighter brush=php,first-line=1,highlight=0,collapse=false,html-script=false]
opentable($locale['op001']);
if (dbrows($result)!= "0") {
echo "<div align='center'><div id='featured'>";
while($data = dbarray($result)) {
echo "<a href='".FUSION_SELF."?readmore=".$info['news_id']."' class='side'>";
echo "<img src='".$info['news_image']."' width='500' height='350' title='".$subject."' alt='".$subject."' border='0' />";
echo "</a>";
}
echo "</div></div>";
} else {
echo $locale['op002'];
}
closetable();
[/syntaxhighlighter]


And this is the error on my website:

CodeDownload  

You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'AND news_cat=11' at line 2



What's wrong? I think the SQL Query is correct. Using it in phpmyadmin to test gives me no error and the correct result. It does show me the news_image.

Any help?
$info['news_id'] is probably empty.
put a
CodeDownload  
var_dump($info);


before your code and see what it gives you.
I get:

CodeDownload  

NULL You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'AND news_cat=11' at line 2

Can you post your full code? You don't instantiate info anywhere, what exactly do you want to achieve? You are currently selecting a specific news item and additionally redundantly filter by news category.
I'm trying to mod the Orbit Panel to show the uploaded news_image from the last X number of news items of a specific category (featured) for example.


[syntaxhighlighter brush=php,first-line=1,highlight=0,collapse=false,html-script=false]
<?php
/*-------------------------------------------------------+
| PHP-Fusion Content Management System
| Copyright © 2002 - 2011 Nick Jones
| http://www.php-fusion.co.uk/
+--------------------------------------------------------+
| Filename: orbit_panel.php
| Version: 1.0
| Author: jikaka
+--------------------------------------------------------+
| This program is released as free software under the
| Affero GPL license. You can redistribute it and/or
| modify it under the terms of this license which you
| can read by viewing the included agpl.txt or online
| at www.gnu.org/licenses/agpl.html. Removal of this
| copyright header is strictly prohibited without
| written permission from the original author(s).
+--------------------------------------------------------*/
if (!defined("IN_FUSION"wink) { die("Access Denied"wink; }

if (file_exists(INFUSIONS."orbit_panel/locale/".$settings['locale'].".php"wink) {
include INFUSIONS."orbit_panel/locale/".$settings['locale'].".php";
} else {
include INFUSIONS."orbit_panel/locale/English.php";
}
require_once INCLUDES."theme_functions_include.php";


add_to_head("
<link type='text/css' href='".INFUSIONS."orbit_panel/css/styles.css' media='screen' rel='stylesheet' />
<script type='text/javascript' src='".INFUSIONS."orbit_panel/js/jquery.orbit-1.2.3.min.js'></script>
<!--[if IE]>
<style type='text/css'>
.timer { display: none !important; }
div.caption { background:transparent; filter:progidgrinXImageTransform.Microsoft.gradient(startColorstr=#99000000,endColorstr=#99000000);zoom: 1; }
</style>
<![endif]-->
<script type='text/javascript'>
$(window).load(function() {
$('#featured'wink.orbit();
});
</script>
"wink;
var_dump($info);
$result=dbquery(
"SELECT * FROM ".$db_prefix."news
WHERE news_id=".$info['news_id']." AND news_cat=11"
);

opentable($locale['op001']);
if (dbrows($result)!= "0"wink {
echo "<div align='center'><div id='featured'>";
while($data = dbarray($result)) {
echo "<a href='".FUSION_SELF."?readmore=".$info['news_id']."' class='side'>";
echo "<img src='".$info['news_image']."' width='500' height='350' title='".$subject."' alt='".$subject."' border='0' />";
echo "</a>";
}
echo "</div></div>";
} else {
echo $locale['op002'];
}
closetable();
?>
[/syntaxhighlighter]

P.D, I don't know PHP (not a lot) nor SQL, but I want to learn ^^
Thanks for your help Matonor. But finally I decided to edit the "MySlide Panel-Center" by HaYaLeT.

You can see it here:

http://www.php-fusion.co.uk/forum/viewthread.php?thread_id=29163&pid=160610#post_160610
With the query in that panel this one would probably have worked as well or would have come closer to working ;-)
jikaka .. i think this zip file is corrupted.. its not working
how to add images?
iam really doesnt have any sliding image. please tell me something
Thread Information
Author
Replies
21 posts
Views
12,650 times
Last Post
Last updated on 5 years ago
You can view all discussion threads in this forum.
You cannot start a new discussion thread in this forum.
You cannot reply in this discussion thread.
You cannot start on a poll in this forum.
You cannot upload attachments in this forum.
You cannot download attachments in this forum.