Author Topic: [MOD] Random image on home page with flash  (Read 37154 times)

0 Members and 1 Guest are viewing this topic.

Offline x23piracy

  • Sr. Member
  • ****
  • Posts: 420
    • View Profile
    • FHG
Re: [MOD] Random image on home page with flash
« Reply #15 on: November 16, 2010, 12:28:53 PM »
Hi,

mit 1.7.9 spuckt die xml.php bei mir nur noch das hier aus:

Code: [Select]
  <?xml version="1.0" encoding="UTF-8" ?>
- <playlist version="1" xmlns="http://xspf.org/ns/0/">
  <trackList />
  </playlist>

keine Bilder die folge... Weiß jemand Rat?


Gruß Jens

Don't trust in md5 it's unsafe change your 4i galerys password hash algorythm! second pw db field, create new hashes over some time, deny old hash. Help members that cry, send informationen mail to the rest. Camouflage new pw hash in cookie. Done!

--(◔̯◔)--

Offline henary

  • Jr. Member
  • **
  • Posts: 73
    • View Profile
Re: [MOD] Random image on home page with flash
« Reply #16 on: December 10, 2010, 10:08:20 AM »
Hello,

thanks for this MOD!

There are two things, that not fine at the moment:

If you use in xml.php and home.html "www.domain.com", the flash will don't work if the gallerie was visit by passing the "www" like http://domain.com/4images I tried to leave "www" in config-settings, but flash don't work anymore. At the moment the only solution may be to disable posibility of using http://domain.com/4images or make forwarding.

For the second i found a small solution for the moment by myself  :wink:

Because the selection of images is setting by
        AND a.cat_id b.cat_id
        
AND b.auth_viewcat=".AUTH_ALL."
        
AND b.auth_viewimage=".AUTH_ALL."

and there are none public pictures at all, but pitcures in categories with permission, nothing will displayed by flash  8O
My easy way:
in xml.php
search:
include(ROOT_PATH.'includes/constants.php');
add after
include(ROOT_PATH.'includes/auth.php');
search:
        AND a.cat_id b.cat_id
        
AND b.auth_viewcat=".AUTH_ALL."
        
AND b.auth_viewimage=".AUTH_ALL."

replace:
        WHERE a.image_active AND a.cat_id b.cat_id AND b.cat_id NOT IN (".get_auth_cat_sql("auth_viewcat", "NOTIN").")

At the moment, this is not fine while guest will see flash images  :cry: and i don't nkow why. May it will be the best, flash images only shown for registered user.

Regards,
Henry

Offline x23piracy

  • Sr. Member
  • ****
  • Posts: 420
    • View Profile
    • FHG
Re: [MOD] Random image on home page with flash
« Reply #17 on: December 10, 2010, 11:41:45 AM »
Hi,

At the moment, this is not fine while guest will see flash images  :cry: and i don't nkow why. May it will be the best, flash images only shown for registered user.

use this surrounding tag:

Code: [Select]
{if user_loggedin}that what you only want to show loggedin users{endif user_loggedin}
for the xml try to use a relative path instead of an absolute:
Code: [Select]
s1.addVariable("file","./xml.php");(You may need to pimp the path, i don't know where your xml.php is stored)

Der Rotator ist aber nur zu empfehlen wenn du das Logo verschmerzen kannst.
Das ganze sieht auch nur schön aus wenn es groß genug ist das Logo ist sonst
über der betrefenden Grafik bis es ausgeblendet wird ;)

Falls du mal das Flash Dock benutzt bekommt man dort das Logo legal durch die
Settings quasi herausgeschoben aus dem sichtbaren Bereich...


Greetz X23
« Last Edit: December 10, 2010, 12:04:40 PM by x23piracy »

Don't trust in md5 it's unsafe change your 4i galerys password hash algorythm! second pw db field, create new hashes over some time, deny old hash. Help members that cry, send informationen mail to the rest. Camouflage new pw hash in cookie. Done!

--(◔̯◔)--

Offline henary

  • Jr. Member
  • **
  • Posts: 73
    • View Profile
Re: [MOD] Random image on home page with flash
« Reply #18 on: December 10, 2010, 11:54:30 AM »
Hello X23,

thanks a lot! Now both working well  :mrgreen:

Regards,
Henry

Offline Nosferatu

  • Full Member
  • ***
  • Posts: 230
    • View Profile
    • Project-Firepower
Re: [MOD] Random image on home page with flash
« Reply #19 on: June 02, 2011, 12:42:00 PM »
Hallo,

work perfect with 1.7.10

Frage:
wie kann ich kategorien ausschließen?

Weiß das jemand ?

mein Code:
// PATH to your 4images Gallery / PFAD zu Ihrer 4images Gallerie
define('ROOT_PATH''./');

include(
ROOT_PATH.'config.php');
include(
ROOT_PATH.'includes/db_mysql.php');
include(
ROOT_PATH.'includes/constants.php');


$site_db = new Db($db_host$db_user$db_password$db_name);
function 
is_remote($file_name) {
  return (
preg_match('#^https?\\:\\/\\/[a-z0-9\-]+\.([a-z0-9\-]+\.)?[a-z]+#i'$file_name)) ? 0;
}

// NUMBER OF IMAGES TO DISPLAY 
$num_images 100;

$sql "SELECT a.image_id, a.cat_id, a.image_name, a.image_active, a.image_thumb_file, a.image_comments
        FROM "
.IMAGES_TABLE." a, ".CATEGORIES_TABLE." b
        WHERE a.image_active=1
        AND a.cat_id = b.cat_id
        AND b.auth_viewcat="
.AUTH_ALL."
        AND b.auth_viewimage="
.AUTH_ALL."
        ORDER BY RAND()
        LIMIT 
$num_images";
$result $site_db->query($sql);
echo 
"<?xml version='1.0' encoding='UTF-8'?>\n";
echo 
"<playlist version=\"1\" xmlns=\"http://xspf.org/ns/0/\">\n";
echo 
"
	
<trackList>\n"
;
while (
$row $site_db->fetch_array($result)){
  
$image_id $row['image_id'];
  
$cat_id $row['cat_id'];
  
$image_name $row['image_name'];
  
$thumb_src = (is_remote($row['image_thumb_file'])) ? $row['image_thumb_file'] : MEDIA_DIR."/".$cat_id."/".$row['image_thumb_file'];
  echo 
"
	
	
<track>\n"
;
  echo 
"
	
	
<title>
$image_name</title>\n";
  echo 
"
	
	
<creator>www.pj-firepower.com</creator>\n"
;
  echo 
"
	
	
<location>http://www.pj-firepower.com/picgallerie/
$thumb_src</location>\n";
  echo 
"
	
	
<info>http://www.pj-firepower.com/picgallerie/details.php?image_id=
$image_id</info>\n";
  echo 
"
	
	
</track>\n\n\n"
;
}
echo 
"
	
</trackList>\n"
;
echo 
"</playlist>\n";


Danke !

Mfg
Nosferatu


Rembrandt

  • Guest
Re: [MOD] Random image on home page with flash
« Reply #20 on: June 02, 2011, 01:03:54 PM »
Nicht getestet.
damit du die kategorien in ACP unter einstellungen editieren kannst:

suche in der admin/settings.php:

show_table_separator
($setting_group[3], 2"setting_group_3");

und füge davor ein:

 
//--------------------------------- Start cat select pic ---------------------------------
	
show_setting_row("cat_pic");
//--------------------------------- End cat select pic ---------------------------------


suche in lang/deutsch/admin.php:

$setting
['num_subcats'] =

und füge davor ein:

//--------------------------------- Start cat select pic ---------------------------------
$setting['cat_pic'] = "Kategorie nicht Anzeigen:<br /><span class=\"smalltext\">ID Nummern mit , trennen.</span>";
//--------------------------------- End cat select pic ---------------------------------


in deinen code suche:
$num_images 100;

darunter einfügen:
$cat_in$config['cat_pic'];


in deine code suche:
WHERE a.image_active=1

danach einfügen:
AND a.cat_id NOT IN (".$cat_in.")


mfg Andi

Offline Nosferatu

  • Full Member
  • ***
  • Posts: 230
    • View Profile
    • Project-Firepower
Re: [MOD] Random image on home page with flash
« Reply #21 on: June 02, 2011, 02:12:39 PM »
danke!

Offline MrAndrew

  • Sr. Member
  • ****
  • Posts: 302
    • View Profile
    • Aviation PhotoBase
Re: [MOD] Random image on home page with flash
« Reply #22 on: August 31, 2011, 11:02:16 PM »
Is it possible to remove "jwplayer" watermark?

Rembrandt

  • Guest
Re: [MOD] Random image on home page with flash
« Reply #23 on: September 01, 2011, 05:50:17 AM »

Offline Nosferatu

  • Full Member
  • ***
  • Posts: 230
    • View Profile
    • Project-Firepower
Re: [MOD] Random image on home page with flash
« Reply #24 on: February 23, 2014, 03:06:39 PM »
Gibts vom ImageRotator keine neue Version oder wurde dieser jetzt einfach in JWPlayer integriert, dieser wäre nämlich schon Version 6.8.

Hatte gehofft ich könnte da ein Upgrade machen.

LG
Jeff

 

Post your comments here