Thread Rating:
  • 1 Vote(s) - 5 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Custom Fields (and I18N)
Draxeiro Wrote:However, for the news pages I would prefer to use different photo's, if possible. So let me rephrase my question:

It is in any way possible to fill the default values of the 2 custom image fields I am using with different values on certain pages (in this case my news pages)?

If you use I18N Special Pages instead of I18N Custom Fields and define different page types.
I18N, I18N Search, I18N Gallery, I18N Special Pages - essential plugins for multi-language sites.
Reply
Hi Guys,
I'm a bit of a Newbie to Getsimple but so far what I see I like. We are looking at rolling out a CMS system to schools as the current one is a bit creaky and not very well supported.

So far through basic problem solving and plugins I have found a solution to most things that our schools need but there seems to be one stumbling block for me so far. I have read these posts multiple times and I am sorry if I have missed anything. I am trying to get a menu item to link to an external site but for the life of me I cant get it to work.

I'm using GetSimple 3.1 and the i18n Customfields plugin 1.8.1.
I have followed the guide of Customizing a custom Field
Name: External link
Label: link
Type: Text Field
Default Value: blank
Save it.

Go to create a new page
Enter the name of the page
Drop the "Page Options"
enter the url in the format of: http://domain.org.uk
hit save updates.
Browse to the site and nothing happens.

Any thought or am I just being a complete dope?

Cheers in advance
Richard
Reply
richard2233 Wrote:I am trying to get a menu item to link to an external site but for the life of me I cant get it to work.

I'm using GetSimple 3.1 and the i18n Customfields plugin 1.8.1.
I have followed the guide of Customizing a custom Field
Name: External link
Label: link
Type: Text Field
Default Value: blank

see here (Internal/External Links):
  1. name must be link
  2. label can be anything
  3. type should rather be link, but text field will work, too
  4. of course you must also check "Add to Menu" and give the page a position in the menu.
I18N, I18N Search, I18N Gallery, I18N Special Pages - essential plugins for multi-language sites.
Reply
I'm having a problem using the Insert Image button in a WYSIWYG custom field. I can browse the server but when I select an image the URL field does not receive the path to the image (it remains empty).

I don't think it is a cookie issue as I have set sitewidecookies in my config and I can browse pages for links. Any ideas what the cause of the problem could be?
Reply
Got a problem: I copied the plugin contents into my /plugin/ directory, then added a new field in the backend UI, but this new field somehow won't appear when I edit a page (or create a new one).
Using GetSimple 3.1, additional plugins: Nested Menus

Any ideas where the problem might be?

Thanks in advance
joene
Reply
Cerulean Wrote:I'm having a problem using the Insert Image button in a WYSIWYG custom field. I can browse the server but when I select an image the URL field does not receive the path to the image (it remains empty).
I am facing the same problem.
Reply
Hi guys,

I'm having a problem with the plugin; when I add <?php get_custom_field('image'); ?> to my template, I just see the path to the image in the frontend rather then the image itself. I'm using GS3.1 with custom fields 1.8.1 and I updated the gsconfig file.

Am I missing something?

Cheers
Reply
Did you insert the custom field call inside the img tag, like so:

Code:
<img src="<?php get_custom_field('image'); ?>" alt="img" />

Plus did you also add the image in the 'configure custom fields'?

That's basically what should be done. By the looks of it you might have forgotten the img tag bit.
Reply
jeroendekker Wrote:Hi guys,

I'm having a problem with the plugin; when I add <?php get_custom_field('image'); ?> to my template, I just see the path to the image in the frontend rather then the image itself. I'm using GS3.1 with custom fields 1.8.1 and I updated the gsconfig file.

Am I missing something?

Cheers


yes, you have to put that into an image tag, like this:
Code:
<img src="<?php get_custom_field('image'); ?>" alt="My Image" />
Reply
Quote:yes, you have to put that into an image tag, like this:
Code:
<img src="<?php get_custom_field('image'); ?>" alt="My Image" />

A, thnx guys! But there is a 'but' Smile

When I put this in my theme and I put a image in it is't ok. But on the next page without a image there is the question mark of a broken image..

(Sorry, newbie Smile)
Reply
jeroendekker Wrote:When I put this in my theme and I put a image in it is't ok. But on the next page without a image there is the question mark of a broken image..

Code:
<?php if (return_custom_field('image')) { ?>
  <img src="<?php get_custom_field('image'); ?>" alt="My Image" />
<?php } ?>
I18N, I18N Search, I18N Gallery, I18N Special Pages - essential plugins for multi-language sites.
Reply
mvlcek Wrote:<?php if (return_custom_field('image')) { ?>
<img src="<?php get_custom_field('image'); ?>" alt="My Image" />
<?php } ?>

Thank you very much! I get it now

Cheers
Reply
i inserted the Image custom fields and when i click on the Browse button the file manager open with my list of images in the upload folder. the problem is why the left side thumbnail of the images list has a broken image with question mark icon? somehow it can't find the thumbnails for that image, if yes, how do i generate those thumbnails?? thanks
Reply
andyash Wrote:I'm having a problem using the Insert Image button in a WYSIWYG custom field. I can browse the server but when I select an image the URL field does not receive the path to the image (it remains empty).

Any solutions to this problem? I am using the WYSIWYG custom filed to insert a lot of images in the sidebar and have to hand over the site to the client. Currently I insert the image inside the main content WYSIWYG area and drag the image from there. But there has to be a right way to solve it. Anyone, please?
Reply
andyash Wrote:I'm having a problem using the Insert Image button in a WYSIWYG custom field. I can browse the server but when I select an image the URL field does not receive the path to the image (it remains empty).
I'm pretty sure this is simply a bug that needs to be fixed. I've just tried inserting an image with a custom WYSIWYG field with a fresh install and it the same thing happens for me.
Modern UI Admin for GetSimple
Watch the demo. Install this plugin. Use this CSS. Enjoy.
Reply
sal Wrote:
andyash Wrote:I'm having a problem using the Insert Image button in a WYSIWYG custom field. I can browse the server but when I select an image the URL field does not receive the path to the image (it remains empty).
I'm pretty sure this is simply a bug that needs to be fixed. I've just tried inserting an image with a custom WYSIWYG field with a fresh install and it the same thing happens for me.
Agreed, but someone still needs to squash it. This problem has been on the forum for a few weeks now but there's been no response to it.
Reply
andyash Wrote:
sal Wrote:
andyash Wrote:I'm having a problem using the Insert Image button in a WYSIWYG custom field. I can browse the server but when I select an image the URL field does not receive the path to the image (it remains empty).
I'm pretty sure this is simply a bug that needs to be fixed. I've just tried inserting an image with a custom WYSIWYG field with a fresh install and it the same thing happens for me.
Agreed, but someone still needs to squash it. This problem has been on the forum for a few weeks now but there's been no response to it.

Are you using GS 3.1?
Are you also using I18N Special Pages?
Any Javascript error?
I18N, I18N Search, I18N Gallery, I18N Special Pages - essential plugins for multi-language sites.
Reply
mvlcek Wrote:Are you using GS 3.1?
Are you also using I18N Special Pages?
Any Javascript error?

GS3.1 - Yes
I18N Special Pages - No
Javascript Error - No
Reply
Hi there,

I want to build an image gallery dynamically depending on the filled customs field. This code does not work. Using firebug shows that the surrounding DIV element stays clear, DEBUG MODE does not show any errors.
Any I ideas whats' wrong?

Thanks, Carsten

<code>
<?php

$ARTICLE_IMAGE_1 = return_custom_field('articleimage1');
$ARTICLE_IMAGE_2 = return_custom_field('articleimage2');
$ARTICLE_IMAGE_3 = return_custom_field('articleimage3');
$ARTICLE_IMAGE_4 = return_custom_field('articleimage4');
$ARTICLE_GALLERY = null;


if( !empty($ARTICLE_IMAGE_1) ||
!empty($ARTICLE_IMAGE_2) ||
!empty($ARTICLE_IMAGE_3) ||
!empty($ARTICLE_IMAGE_4)){
$ARTICLE_GALLERY = '<ul id="article_gallery">';} else {}
if(!empty($ARTICLE_IMAGE_1)){
$ARTICLE_GALLERY .= '<li><img class="" src="' . $ARTICLE_IMAGE_1 . '" /></li>';} else {}
if(!empty($ARTICLE_IMAGE_2)){
$ARTICLE_GALLERY .= '<li><img class="" src="' . $ARTICLE_IMAGE_2 . '" /></li>';} else {}
if(!empty($ARTICLE_IMAGE_3)){
$ARTICLE_GALLERY .= '<li><img class="" src="' . $ARTICLE_IMAGE_3 . '" /></li>';} else {}
if(!empty($ARTICLE_IMAGE_4)){
$ARTICLE_GALLERY .= '<li><img class="" src="' . $ARTICLE_IMAGE_4 . '" /></li>';} else {}
if( !empty($ARTICLE_IMAGE_1) ||
!empty($ARTICLE_IMAGE_2) ||
!empty($ARTICLE_IMAGE_3) ||
!empty($ARTICLE_IMAGE_4)){
$ARTICLE_GALLERY .= '</ul>';} else {}
echo $ARTICLE_GALLERY;
?>
</code>
Reply
andyash Wrote:
Cerulean Wrote:I'm having a problem using the Insert Image button in a WYSIWYG custom field. I can browse the server but when I select an image the URL field does not receive the path to the image (it remains empty).
I am facing the same problem.

This is a bug/feature in GS 3.1, see this topic.

Quick fix (patch): edit admin/filebrowser.php and replace line
Code:
if ($funcNum=="2"){
with
Code:
if ($funcNum/*=="2"*/){

Or update to GS 3.1.1 where this should be corrected... :-)
I18N, I18N Search, I18N Gallery, I18N Special Pages - essential plugins for multi-language sites.
Reply
mvlcek Wrote:
andyash Wrote:
Cerulean Wrote:I'm having a problem using the Insert Image button in a WYSIWYG custom field. I can browse the server but when I select an image the URL field does not receive the path to the image (it remains empty).
I am facing the same problem.

This is a bug/feature in GS 3.1, see this topic.

Quick fix (patch): edit admin/filebrowser.php and replace line
Code:
if ($funcNum=="2"){
with
Code:
if ($funcNum/*=="2"*/){

Or update to GS 3.1.1 where this should be corrected... :-)
Updating to 3.1.1 did not help me. Its filebrowser.php does not allow me to import images in any of the WYSIWYG editors. But replacing its original code
Code:
<script type='text/javascript'>
    function submitLink($funcNum, $url) {
        if ($funcNum!=""){
            if(window.opener){
                window.opener.CKEDITOR.tools.callFunction($funcNum, $url);
            }
        }
        <?php if (isset($_GET['returnid'])){ ?>
            if(window.opener){
                window.opener.document.getElementById('<?php echo $returnid; ?>').focus();
                window.opener.document.getElementById('<?php echo $returnid; ?>').value=$url;
            }
        <?php } ?>    
        <?php if (isset($_GET['func'])){
        $func = @$_GET['func']; ?>
            if(window.opener){
                window.opener.<?php echo $func; ?>('<?php echo $returnid; ?>');
            }
        <?php } ?>    
        window.close();
    }
    </script>
with the patch in your suggested link
Code:
<script type='text/javascript'>
    function submitLink($funcNum, $url) {
        <?php if (isset($_GET['returnid'])){ ?>
            if(window.opener){
                window.opener.document.getElementById('<?php echo $returnid; ?>').value=$url;
            }
        <?php } else { ?>
            if(window.opener){
                window.opener.CKEDITOR.tools.callFunction($funcNum, $url);
            }
        <?php } ?>
        window.close();
    }
    </script>
makes them both work fine.
Reply
I18N Custom Fields version 1.8.3:
  • solves a display problem with link/image fields
  • includes danish and dutch translations (thanks @chrsand and @Draxeiro)
I18N, I18N Search, I18N Gallery, I18N Special Pages - essential plugins for multi-language sites.
Reply
Is there a way I can use the custom fields plugin to add multiple values? What I want is a simple way to add unlimited images to a page, which I can then do whatever I want with in the template. At the moment the plugin only allows one value, which means that I would have to add a field for every possible image added.

Alternatively, is there a gallery plugin which allows me to access the image data (in an array for example) in the template, rather than in a pre-formatted gallery view?

Thanks!
Reply
(2012-10-26, 15:40:30)mrchristoph Wrote: Is there a way I can use the custom fields plugin to add multiple values? What I want is a simple way to add unlimited images to a page, which I can then do whatever I want with in the template. At the moment the plugin only allows one value, which means that I would have to add a field for every possible image added.

Alternatively, is there a gallery plugin which allows me to access the image data (in an array for example) in the template, rather than in a pre-formatted gallery view?

Couldn't you use the WYSIWYG editor, and put your images in there? Then you could insert as many as you want.
Reply
I've just found that when changing the path for the admin folder to something else, the customfields plugin files filebrowser.php and pagebrowser.php are not being bypassed and return errors in the chooser window; i.e.:

Warning: include(../../../admin/inc/common.php) [function.include]: failed to open stream: No such file or directory in /var/sites/p/*SITENAME*.com/public_html/plugins/i18n_customfields/browser/filebrowser.php on line 7

I activated the new path in gsconfig and everything else works fine apart from the custom fields - this has happened on three sites I've done, all on different servers from fresh installations so it doesn't look like its down to incorrect installation on my part etc.

If I have missed anything, please let me know so I don't do it again!
Reply




Users browsing this thread: 2 Guest(s)