-
Posts
4,077 -
Joined
-
Last visited
-
Days Won
87
Everything posted by horst
-
Ah, good to hear. I have used Photoshop CS5 to inspect & play with the images. It is always the best practice (if possible!) to upload unoptimized images with max quality to use them as the original source only. The only downside is that you cannot / should not serve those original source to the public. (But you can serve a variation with identical dimensions, but optimized and/or with lesser quality).
-
@soma: the above attached images seem to work fine here on my machine. ?? I don't see those lines. But in the past there were other images that had some artefacts. It mostly depends on settings for defaultGamma, sharpening and if sharpening uses USM (useUSM) or not. I suggest you try / experiment with the following options: $options = array( "forceNew" => true, "defaultGamma" => -1, // disable Gammacorrection "sharpening" => "none", // disable sharpening or use "soft" "useUSM" => true // use USM or disable it with false ); Sorry that I cannot more helpful with this. I used PW 2.6 stable and GD-lib with PHP 5.3 and PHP 5.4.
-
If you like, I can have a look at it if you pm me one of the original trasparent png images.
-
Martin, I would go with a fileupload field, not with an image field. If this has to do with the project we have talked about, you can copy / create a new inputfield of the default file upload field or use the default file-field and hook into file_added to further process the uploaded images with e.g. imagick or equivalent software on the server. PS: @Lostkobrakai, you are mainly right with what you say here, but I would avoid any clientside imageprocessing and only let the users upload the high quality file because there is a good chance that it will be a mix of RGB and CMYK files (maybe grayscaled too) each colorspace with different ICC-Profiles, what I think isn't handled by clientside imageuploaders.
-
when under fields: edit field -> tab input -> required [x] you can tip the checkbox, (like with the title field).
-
Hi Martin, if the filesize limit is 50 MB, the post_max_size should be a bit higher. I think it has to do with that post data is encoded so that the final post data is always greater than the original binary file data. Can you try upload_max_filesize 50M and post_max_size 65M?
-
this line will not work I believe: $p->parent = wire('pages')->get('/$parent/'); //set the parent '/$parent/' : if you use it with a variable as shown in your code, you must surround it with doublequotes: "/$parent/". Variables will not be populated within singlequotes. ------ Where is the code (line) where you check for existing records? Are there unique fields in your drupal data with the records that you can use? steps to do: 1) read (next) record from drupal source 2) fetch and prepare data for a unique identifier from it This can be a unique field within the drupal data, or, if this is not present, create a selector that may contain sanitized values for name / author / date or what is the best for your data. 3) do a get() with this selector If the page exists, modify it where needed or move on to the next record. If it do not exist, create it and populate fields.
-
$a->import($items); . or one of the other methods that are available with pagearrays / wirearrays.
-
I'm not completely sure if this is possible within the admin, but I think yes: one way can be to build a simple little module, another way can be to use one of the new implemented _ready.php | _install.php etc. files, if you use the one of the latest dev versions (PW 2.6.9+ ??) But regardless of that, you need to hook into after InputfieldURL::render Within your function you fetch the result ($event->return) and the url, if any given and prepend an image tag to the result. pseudo code, simplified: $url = ... ; // you need to fetch the url here $event->return = "<img src='{$url}' width='100' alt='' />" . $event->return; $event->replace = true; . EDIT: After rethinking it, I think you need to build a little custom module and cannot use the new _ready.php etc. files, but would be nice if some one can clarify this more precisly than I currently can.
-
I thought we are never ever advised to edit wire/config.php, we are strongly advised to edit site/config.php Or do I miss something new?
-
With the http404 page I sometimes get a SQL-Error notification
horst replied to horst's topic in General Support
Ah, ok. It's an error ID. Feels like "thin air", -
With the http404 page I sometimes get a SQL-Error notification
horst replied to horst's topic in General Support
Oh, thanks, thats very helpful. I have a cron running there that starts a bootstrapped script two times per day. I think I put in some code to make it first login as a special user to be sure that it is the script that produces sometimes the errors. A bit weird with the error message is, that a page with ID 1062 exists, but it get not touched with the bootstrapped script. Also I have dumped the complete DB into an editor and searched for the string '41-0', but it isn't present, not only one times. And yes, it is a little annoying if one do not know this. The first thing I have done was uninstalling a module (jumplinks) that can be configured to deal with 404s. I've put all redirects into the htaccess file and after that for two weeks no error occured. But than it occured again without any further change on the site. -
Every now and then (once a week or lesser) I get emailed the following error notification on one site that's running PW 2.6: Page: http://example.com/http404/ User: guest Error: Exception: SQLSTATE[23000]: Integrity constraint violation: 1062 Duplicate entry '41-0' for key 'PRIMARY' (in /www/htdocs/example.com/wire/core/FieldtypeMulti.php line 261) Does someone know what I may have missconfigured or what is responsible for it / where I should look into?
-
Module: Spex: An asset and template management module
horst replied to Jonathan Dart's topic in Modules/Plugins
Does you have the folder and file mentioned in the error: site/templates/layouts/default.php? means: does it exist? AFAIK does SPEX want/need to copy some files during installation to site/templates/layouts/ and in regard of the filesystem settings this may have failed without notice. But the default files it uses are _base.php and one-column.php, but not default.php. So, with the template / page you are loading you must have set $spex->setLayout('default'); Does that help? -
I would also check database setting: database character encoding should be utf-8 template files need to be utf-8 encoded HTML-Output need to be utf-8 encoded (header)
-
@valan: makes sense!
-
@valan: I don't know the answer but are a bit courious why you not simply try it out? I would expect that this is handled by PW internally and that there is nothing to do manually. But I haven't worked with this and therefore only assuming.
-
Problems with rendered page - double div-Elements
horst replied to FrankM's topic in General Support
You are welcome. Thats what the forum (besides others) is for: asking for help with problems you cannot solve yourself. It is not bothering. So, - nice to hear it is solved now! PS: also I only was able to think about that solution because of your well sorted and formulated question / description. At least, _you_ gave the answer by yourself. I only was able to see it, whereas you wasn't because you did not have had the distance for a clear view. -
Required field error showing when add images via API
horst replied to alexcapes's topic in API & Templates
@gebeer: That's "the same in green" - When saving in a method that is triggered before saving (regardless if before_saving or if save_ready) every save action triggers it once more. -
Problems with rendered page - double div-Elements
horst replied to FrankM's topic in General Support
have you looked into the ckeditor content in one of those pages in editmode? (Sourcecode of the ckeditor field). Could it be you have copied from your local installation and pasted into the ckeditor field of the online version? This way it would be possible that one of those divs (the inner one) was included with the copy / paste action and now lives in the field content of three pages. Just a thought, maybe wrong. PS: welcome to PW -
Required field error showing when add images via API
horst replied to alexcapes's topic in API & Templates
Hey guys, I'm not 100% sure, but hooking before_save and than saving within the module looks not completly clean to me. Maybe I'm not right, but I would try it once without saveing in the module, because saving is done directly after the modules hook function is executed. -
max image dimensions - "not a recognized image" [bug?]
horst replied to bernhard's topic in General Support
can you PM me the original? -
Luckily I do not have to work with WP sites, as I'm also build very less sites, mostly private things. There is only one site that was built with WP, it's a private site for my son and me. We haven't made any updates to it since two years. And I want to port it to PW since I know PW, but haven't found the time until now. My 10 years old son has made some photos that he wants to see on the homepage there and I need to remember where the admin / backend / login page was. I tried some URLs that all fail. Than I opened a FTP client and looked to the directory structure and found the name of the subfolder which contains the wp-admin folder. After typing this URL and failing again I got a bit dazzled and was talking / grumbling to myself. My son began to laugh and rolling over the floor and shouts: "You are not able to write wp-admin you have written pw-admin. Everything you can think of is PW!". And he is right: after finding PW, I just want to wipe out any past memory regarding WP. After porting this site I can fullfill this to 100%. Until then I have to live with mistakes like pw-admin.
-
Maybe it is possible for you to switch to croppableImages as it returns pageimages that you can resize further. The original CropImage does return a URL, not a pageimage object.
-
If the user can select multiple files for download, you know where they are. You simply can link to the page(s) of them if you have set the new property of mimetype for that template. Then PW will send the apropriate headers for that mime type. But I would bundle all selected files into one ZIP and present that link for downloading.