collapse

* Simple Portal Archived Forum

This is an Archive Forum.

The content in this forum may be out-of-date or have been superseded by newer information, and links in forum pages to other sites may not work.
This forum contains archives for future reference.

Visit our thread at Simple Machines Forum for current support.

SMF 2.1 users: EhPortal is a ported version of Simple Portal specifically designed for the SMF 2.1 branch.
Please visit web-develop.ca to download EhPortal and for its support.

* User Info

 
 
Welcome, Guest. Please login or register.

* Who's Online

  • Dot Guests: 367
  • Dot Hidden: 0
  • Dot Users: 0

There aren't any users online.

* Shoutbox

Refresh History
  • Shoutbox is not for support!
  • {OCS}MasterSeal: Yup, Still adore SP
    April 21, 2019, 07:08:06 PM
  • {OCS}MasterSeal: STILL love SP :)
    November 24, 2018, 05:05:50 AM
  • ♦ Ninja ZX-10RR ♦: <3 aegersz
    September 13, 2018, 03:36:09 PM
  • aegersz: I STILL <3 LOVE SimplePortal
    September 13, 2018, 07:11:39 AM
  • aegersz: o LOVE you guys - Simple Portal rocks !
    May 09, 2018, 05:18:59 AM
  • Chen Zhen: our apologies for the site being down.. please read server issues topic
    March 22, 2018, 05:32:38 AM
  • {OCS}MasterSeal: LOL PLEASE forget I just posted that. I found the answer in my own dang post back in 2015. lol sorry!
    July 04, 2017, 10:47:55 PM
  • {OCS}MasterSeal: I know this SB isnt' for support, but I just have a general question. Who would I contact to find out where SP stores its block info? Is it DB driven or files? I searched the site but came up with nothing. probably my fault any insight is appreciated.
    July 04, 2017, 10:43:36 PM
  • ♦ Ninja ZX-10RR ♦: Excuse me but what does Simpleportal have to deal with that?
    February 05, 2017, 08:21:14 PM
  • WhiteEagle: of course IMHO that site appears to be dead :(
    February 04, 2017, 01:08:05 PM
  • WhiteEagle: If I can get that, then I'll use it for that site...
    February 04, 2017, 01:07:35 PM
  • WhiteEagle: decided to not use SMF for any projects, unless I can get a copy of the premium version of the fanfiction archive plugin
    February 04, 2017, 01:06:54 PM
  • expertdecisions: cloudflare
    January 28, 2017, 08:01:47 AM
  • aegersz: SM release 2.0.13 !
    January 12, 2017, 06:00:13 AM
  • raffo: Tks Emanuele, even if I didn't understand the fix :D
    November 07, 2016, 02:01:20 AM
  • emanuele: [link]
    November 01, 2016, 12:43:50 PM
  • emanuele: raffo: the English support board is a good place. ;)
    November 01, 2016, 12:43:38 PM
  • raffo: Where can I find the fix for the shoutbox?
    November 01, 2016, 05:06:09 AM
  • {OCS}MasterSeal: To the SP team, I make a point to come here and thank you as much as possible for your work.  so again, THANK YOU!
    October 28, 2016, 10:38:05 AM
  • emanuele: That's indeed funny, the limit is present only in the patch and not the full install.
    October 22, 2016, 06:14:58 PM

* Recent Posts

Adding Forums Button to Nav bar by jirapon
[August 01, 2019, 09:07:12 AM]


Re: Board Icons by ♦ Ninja ZX-10RR ♦
[July 30, 2019, 04:03:41 PM]


MOVED: Czech translation???? by ♦ Ninja ZX-10RR ♦
[July 30, 2019, 03:04:51 PM]


Board Icons by jirapon
[July 30, 2019, 07:28:44 AM]


Re: Thankyou Simpleportal, by ♦ Ninja ZX-10RR ♦
[July 29, 2019, 09:41:29 AM]

Thanks for having an interest with our portal. If you have any requests for features, have a look at the Feature Requests board.

Author Topic: Aeva Media Block  (Read 84784 times)

0 Members and 1 Guest are viewing this topic.

Offline vyache

  • Semi Newbie
  • *
  • Posts: 8
  • SMF Version: 2 RC2
  • SP Version: 2.3.1
Re: Aeva Media Block
« Reply #20 on: January 31, 2010, 11:03:52 PM »
I get issues with permissions, as admin the pictures don show for some reason...

using the following code...
Code: [Select]
function show_aeva_media_block()
{
   global $sourcedir;

   // Load the language file
   loadLanguage('Aeva');

   // Grab the file.
   if (file_exists($sourcedir . '/Aeva-Subs.php'))
      require_once($sourcedir . '/Aeva-Subs.php');
   // If it doesn't exist, tell them this and stop running.
   else
   {
      echo '<b>You don\'t have Aeva installed! Unable to continue!</b>';
      return;
   }

   // Use aeva functions to show the media.
   echo aeva_listItems(aeva_getMediaItems(0, 4, 'RAND()'), false, '', 1);
}

// Run the function.;
show_aeva_media_block();

Offline Chen Zhen

  • The Underdog
  • Operations Manager
  • *
  • Posts: 1350
  • Gender: Male
  • Kinesis
    • WebDev
  • SMF Version: 2.1
  • EhPortal Version: 1.22
Re: Aeva Media Block
« Reply #21 on: February 01, 2010, 02:27:58 PM »
     Hmmmmm - that code looks different than what is provided above and using the above code and changing false to true, does nothing still.

     Until i can get it the way i want ( "1" most recent media image centered ), i changed it to 2 images and had to expand the size of all blocks to 250 wide and it looks good now though i would prefer to keep my blocks at 200. At 200, it created a bottom scroll bar with two images.

It works for me.
 Here is the whole code block that is set to 4 random pics:
Code: [Select]
function show_aeva_media_block()
{
   global $sourcedir;
// Set amount visible
$visible = "4";
   // Load the language file
   loadLanguage('Aeva');

   // Grab the file.
   if (file_exists($sourcedir . '/Aeva-Subs.php'))
      require_once($sourcedir . '/Aeva-Subs.php');
   // If it doesn't exist, tell them this and stop running.
   else
   {
      echo '<b>You don\'t have Aeva installed! Unable to continue!</b>';
      return;
   }

   // Use aeva functions to show the media.
   $images = aeva_listItems(aeva_getMediaItems(0, $visible, 'RAND()'), true, '', 0);
$show = '<div id="aeva_pics" style="width: 100%;" overflow="visible">'. $images. '</div>';
echo $show;
return;
}   
// show the contents
show_aeva_media_block();


UD
« Last Edit: February 01, 2010, 02:31:18 PM by Underdog »

Offline curlin

  • Jr. Member
  • **
  • Posts: 52
  • Gender: Male
    • Thoroughbred Junkie
  • SMF Version: 2 RC2
  • SP Version: 2.3.1
Re: Aeva Media Block
« Reply #22 on: February 01, 2010, 02:39:57 PM »
     Just re-entered the script you just posted and changed the "4" to a "1" and it is left aligned again  :(
Hoss Talk At Thoroughbred Junkie

Offline Chen Zhen

  • The Underdog
  • Operations Manager
  • *
  • Posts: 1350
  • Gender: Male
  • Kinesis
    • WebDev
  • SMF Version: 2.1
  • EhPortal Version: 1.22
Re: Aeva Media Block
« Reply #23 on: February 01, 2010, 02:43:17 PM »
     Just re-entered the script you just posted and changed the "4" to a "1" and it is left aligned again  :(

Why would you change it to 1??

That only shows 1 picture. The purpose of what was written there was to show a few (4 in the example) in a horizontal view as opposed to wiz's original post which shows them vertically.

UD


Offline curlin

  • Jr. Member
  • **
  • Posts: 52
  • Gender: Male
    • Thoroughbred Junkie
  • SMF Version: 2 RC2
  • SP Version: 2.3.1
Re: Aeva Media Block
« Reply #24 on: February 01, 2010, 02:50:38 PM »
   What i wanted from this block script was to show the most recent image (1) centered in a block. If i use 2 or 4, i have to increase the size of all portal blocks from 200 to 250 because it creates a bottom scrollbar. Go easy on me as i'm just learning.
Hoss Talk At Thoroughbred Junkie

Offline Chen Zhen

  • The Underdog
  • Operations Manager
  • *
  • Posts: 1350
  • Gender: Male
  • Kinesis
    • WebDev
  • SMF Version: 2.1
  • EhPortal Version: 1.22
Re: Aeva Media Block
« Reply #25 on: February 01, 2010, 04:17:36 PM »
   What i wanted from this block script was to show the most recent image (1) centered in a block. If i use 2 or 4, i have to increase the size of all portal blocks from 200 to 250 because it creates a bottom scrollbar. Go easy on me as i'm just learning.


Just add a center tag.
Try this...

Code: [Select]
function show_aeva_media_block()
{
   global $sourcedir;
// Set amount visible
$visible = "4";
   // Load the language file
   loadLanguage('Aeva');

   // Grab the file.
   if (file_exists($sourcedir . '/Aeva-Subs.php'))
      require_once($sourcedir . '/Aeva-Subs.php');
   // If it doesn't exist, tell them this and stop running.
   else
   {
      echo '<b>You don\'t have Aeva installed! Unable to continue!</b>';
      return;
   }

   // Use aeva functions to show the media.
   $images = aeva_listItems(aeva_getMediaItems(0, $visible, 'RAND()'), true, '', 0);
$show = '<div id="aeva_pics" style="width: 100%;" overflow="visible"><center>'. $images. '</center></div>';
echo $show;
return;
}   
// show the contents
show_aeva_media_block();

But change the 4 to a 1 or 2 if that's all you want.

UD

Offline curlin

  • Jr. Member
  • **
  • Posts: 52
  • Gender: Male
    • Thoroughbred Junkie
  • SMF Version: 2 RC2
  • SP Version: 2.3.1
Re: Aeva Media Block
« Reply #26 on: February 01, 2010, 04:32:01 PM »
     You the man  :applause:

                      Thanks
« Last Edit: February 01, 2010, 10:41:37 PM by curlin »
Hoss Talk At Thoroughbred Junkie

Offline ccbtimewiz

  • Hero Member
  • *****
  • Posts: 2185
  • Gender: Male
  • $("div.content:dd").hide();
  • SMF Version: None
  • SP Version: None
  • Elkarte Version: None
  • EhPortal Version: None
Re: Aeva Media Block
« Reply #27 on: February 01, 2010, 10:25:38 PM »
Better:

Code: [Select]
function show_aeva_media_block()
{
global $sourcedir;

// Set amount visible
$visible = 4;

// Load the language file
loadLanguage('Aeva');

// Grab the file.
if (file_exists($sourcedir . '/Aeva-Subs.php'))
require_once($sourcedir . '/Aeva-Subs.php');

// If it doesn't exist, tell them this and stop running.
else
{
echo '<b>You don\'t have Aeva installed! Unable to continue!</b>';
return;
}

// Use aeva functions to show the media.
$images = aeva_listItems(aeva_getMediaItems(0, $visible, 'RAND()'), true, '', 0);

echo '
<div id="aeva_pics" style="width: 100%;" overflow="visible">
<div align="center">'. $images. '</div>
</div>';
}

show_aeva_media_block();

Offline curlin

  • Jr. Member
  • **
  • Posts: 52
  • Gender: Male
    • Thoroughbred Junkie
  • SMF Version: 2 RC2
  • SP Version: 2.3.1
Re: Aeva Media Block
« Reply #28 on: February 01, 2010, 10:42:14 PM »
 :applause: and you too CCB
Hoss Talk At Thoroughbred Junkie

Offline chep

  • Semi Newbie
  • *
  • Posts: 10
  • SMF Version: 1.1.10
  • SP Version: 2.3
Re: Aeva Media Block
« Reply #29 on: February 04, 2010, 12:28:14 AM »
Your mileage may vary. With the code listed below it brought my site to a complete crawl. I would recommend paying attention to performance after enabling it. Page load times during peak hours was between 5-10 seconds. Up from an average of .05 seconds. I monitored this from the status.php

Code: [Select]
loadLanguage('Aeva');
@include_once($sourcedir . '/Aeva-Subs.php');
echo aeva_listItems(aeva_getMediaItems(0, 1, 'RAND()'), false, '', 1);
« Last Edit: February 04, 2010, 12:34:34 AM by chep »

Offline ccbtimewiz

  • Hero Member
  • *****
  • Posts: 2185
  • Gender: Male
  • $("div.content:dd").hide();
  • SMF Version: None
  • SP Version: None
  • Elkarte Version: None
  • EhPortal Version: None
Re: Aeva Media Block
« Reply #30 on: February 04, 2010, 01:51:15 AM »
Did the version I rewrote work better in your environment?

Offline Succubus Evaligan

  • Semi Newbie
  • *
  • Posts: 19
  • Gender: Female
  • yes, Yuri for girls ^.^
    • Yurilandia
  • SMF Version: 1.1.11
  • SP Version: 2.3.2
Re: Aeva Media Block
« Reply #31 on: February 04, 2010, 01:56:08 AM »
I hope that Simple Portal have this by default in their next release. :thumbsup:

Offline Stigmartyr

  • Jr. Member
  • **
  • Posts: 72
  • Gender: Male
  • SMF Version: 2 RC2
  • SP Version: 2.3.1
Re: Aeva Media Block
« Reply #32 on: February 07, 2010, 06:25:43 AM »
How can I get the thumbs to display horizontally?  I like the vertical display for my columns, but in the forums I wanted to list a few horizontally across the top.  Everything I've tried just displays them vertically :(

I also want to display from a specified folder.  Usually there is an 'array' code I can put the album number in there..

Thank you!
« Last Edit: February 07, 2010, 06:31:02 AM by Stigmartyr »

Offline rgecy

  • Just Registered
  • Posts: 1
  • SMF Version: 2 RC2
  • SP Version: None
Re: Aeva Media Block
« Reply #33 on: February 07, 2010, 10:35:05 AM »
The vertical code is working great.  Thanks for the help.

How can I get it to display just the most recent images?

Thanks,

Robert

Offline chep

  • Semi Newbie
  • *
  • Posts: 10
  • SMF Version: 1.1.10
  • SP Version: 2.3
Re: Aeva Media Block
« Reply #34 on: February 09, 2010, 12:37:57 AM »
Did the version I rewrote work better in your environment?

Not really. The performance problem was in the SQL query that is part of AEVA Media. Since the release of Version 1 came out I installed it just a few days ago. Nao calls this function out in his release notes of AEVA Media Version 1 final and he addressed this performance issue. The performance is much better with that release.

Offline Stigmartyr

  • Jr. Member
  • **
  • Posts: 72
  • Gender: Male
  • SMF Version: 2 RC2
  • SP Version: 2.3.1
Re: Aeva Media Block
« Reply #35 on: February 09, 2010, 12:41:55 AM »
Can a certain album be specified with that code above?

Offline Succubus Evaligan

  • Semi Newbie
  • *
  • Posts: 19
  • Gender: Female
  • yes, Yuri for girls ^.^
    • Yurilandia
  • SMF Version: 1.1.11
  • SP Version: 2.3.2
Re: Aeva Media Block
« Reply #36 on: February 09, 2010, 01:26:44 AM »
Now with the oficial release of Aeva Media v1.0 Final (not more alpha or beta). I hope that we can have now a Aeva Mod for the Simple Portal or we can wait until the developers add this feature to support Aeva Media in the next release of Simple Portal.

Offline Stigmartyr

  • Jr. Member
  • **
  • Posts: 72
  • Gender: Male
  • SMF Version: 2 RC2
  • SP Version: 2.3.1
Re: Aeva Media Block
« Reply #37 on: February 10, 2010, 04:00:24 PM »
Can someone help me modify the block code attached below?  I want it to display items horizontally rather than vertically.  I don't know if it means a new code or a modification of the one I have.

Offline gmoneyluv

  • Semi Newbie
  • *
  • Posts: 11
  • SMF Version:1.1.11 SP Version:2.3.1
  • SMF Version: 1.1.11
  • SP Version: 2.3.1
Re: Aeva Media Block
« Reply #38 on: February 19, 2010, 11:13:08 AM »
Hey Folks,

Not sure if i should start a new thread but i'm having issues with the Aeva 1.0 and the gallery block.

I used the code at the start of this thread and still no luck.

See here http://www.ontarioclimbing.com/forum/index.php
Any help???
SMF Version:    1.1.11
SP Version:    2.3.1

Offline gmoneyluv

  • Semi Newbie
  • *
  • Posts: 11
  • SMF Version:1.1.11 SP Version:2.3.1
  • SMF Version: 1.1.11
  • SP Version: 2.3.1
Re: Aeva Media Block
« Reply #39 on: February 19, 2010, 07:53:54 PM »
Ok! Getting closer! Applied the solutions above and they worked but i'm getting a missing picture icon and when i click on the missing picture i get a 406 Not Acceptable error (see attachment).

Any ideas?

Here is web address to my site.
http://www.ontarioclimbing.com/forum/index.php?www
     
SMF Version:    1.1.11
SP Version:    2.3.1