Search results

  1. Jaxel


  2. Jaxel

    XF 2.1 \XF\Util\File::copyFileToAbstractedPath doesn't seem to work anymore for SVG?

    I am using the following code to copy an SVG image from a URL to my server: \XF\Util\File::copyFileToAbstractedPath('', 'data://test.svg'); This used to work... but now it just stuffs an empty file into test.svg. Any ideas on how to fix this?
  3. Jaxel

    XF 2.1 Entity relation is not populated when using a key in relation?

    I have a relation in my $package: 'Pages' => [ 'entity' => 'EWR\Scoreboard:Page', 'type' => self::TO_MANY, 'conditions' => 'package_id', 'order' => 'page_order', ], If I do: \XF::dump($package->Pages);, I...
  4. Jaxel

    XF 2.1 Is it possible to order a finder query by varchar length?

    $this->finder('EWR\Carta:Page') ->order('page_name', 'ASC') ` I have a simple query... but I would prefer to order it by CHAR_LENGTH(page_name) DESC first. How would I do this?
  5. Jaxel

    XF 2.1 Gmail Bounce and Unsub handlers stopped working...

    I've started getting these errors: Unsubscribe connection error: cannot connect to host ; error = fsockopen(): unable to connect to ssl:// (Connection timed out) (errno = 0 ) Bounce connection error: cannot connect to host ; error = fsockopen(): unable to connect to...
  6. Jaxel

    XF 2.1 How can I message all members who use Facebook second-sign-on?

    Facebook has disabled my app for some reason... no idea why, and their ****ty customer support just keeps replying with canned responses that explain nothing. How can I message all users on my forum who have a connected account to Facebook?
  7. Jaxel

    XF 2.1 When are attachments linked to posts?

    I am trying to run a function when a post is made. It's based on what images are attached to that post. I've tried running the function in the _postSave() function of a post; but at that point, the post will still have zero attachments linked to it... even though I am posting with attachments...
  8. Jaxel

    XF 2.1 Does XF2 use custom select menus anywhere?

    I want to do a select menu, but for each select option, I want some HTML formatting in it. Does XF2 have any uses of this? Or will I have to program it myself?
  9. Jaxel

    XF 2.1 IF NOT ISNULL with the XF2 finder system?

    If I am fetching results from a table called packages, with the relation of colors, I could do the following: $this->finder('EWR\Addon:Package') ->with(['Color']) ->fetch(); However, what if I wanted to do the equivalent of: SELECT ... IF(NOT ISNULL(color.color_id)...
  10. Jaxel

    XF 2.1 Modifying xf:dateinput via code?

    Lets say I have a dateinput: <xf:dateinput name="date" class="date-picker" value="{{ date($xf.time+86400, 'Y-m-d') }}" /> Then in my JS, I am connecting to that date picker as follows: $datepicker = this.$target.find('.date-picker'); How can I then change the contents of the data picker, and...
  11. Jaxel

    XF 2.1 UserGroupChange service and forceset?

    I have a function in a repository that is getting activated during an entity _postSave(). $userGroupChange = \XF::service('XF:User\UserGroupChange'); $userGroupChange->addUserGroupChange($user->user_id, $unique_id, $groups); The problem with this, is the following error: How should I get...
  12. Jaxel

    XF 2.1 Finder Where In Array or Empty?

    I have a blob column, lets call it my_blob... This is a JSON_ARRAY in my entity. The array will contain a list of numbers, something like ["1","2","4","8"]. I want to then compare this array, to another array in a finder. Lets say my array $numbers = ["1","5"]. Basically, I want to search for...
  13. Jaxel

    XF 2.1 Changing color picker text in JS?

    I have a color picker on my form: <div class="inputGroup inputGroup--joined inputGroup--color" data-xf-init="color-picker"> <span class="inputGroup-text">{$field.field_key}_{$i}</span> <xf:textbox class="colors c{$i} {$field.field_key}_{$i}" name="fields[{$field.field_key}_{$i}]"...
  14. Jaxel

    XF 2.1 Entity Relations based on a content type?

    Right now I have a relation in my entity based on a content_id: $structure->relations = [ 'Thread' => [ 'entity' => 'XF:Thread', 'type' => self::TO_ONE, 'conditions' => 'content_id', 'primary' => true, ], ]; This of course...
  15. Jaxel

    XF 2.1 Upload form limits to 20 files?

    I have an upload row in my addon: <xf:uploadrow name="uploads[]" label="{{ phrase('image') }}" multiple="true" accept=".gif,.jpeg,.jpg,.jpe,.png" /> And then in php: $uploads = $this->request->getFile('uploads', true, false); As you can see, it accepts multiple files. However, something I...
  16. Jaxel

    XF 2.1 How do I stop browsers from auto-filling a field?

    I've got a form field: <xf:textboxrow class="host" name="page[page_options][host]" label="{{ phrase('host') }}" value="{$}" placeholder="" /> <xf:textboxrow class="port"...
  17. Jaxel

    XF 2.1 Dynamically change the sharePage widget?

    Is there a way to dynamically change the sharePage widget? Specifically the title? I have a text field on my page, and whenever that field is changed, I would like the title of the sharePage links to change with it. I have tried the following, to no effect...
  18. Jaxel

    XF 2.1 xf:selectrow with changing explain text?

    Is there a built in way to have the explain text on a selectrow change depending on what the user has selected? Or do I have to program that myself into the javascript?
  19. Jaxel

    XF 2.1 Javascript Confirm Box, in XF Styling?

    In JavaScript, you can do prompt() or confirm() to introduce an action request from the end user. Does XF have a system like this built in? Something that doesn't require any server interaction, just a momentary pause in the javascript flow?
  20. Jaxel

    XF 2.1 Hotlink Protection on a /data folder?

    I'm trying to prevent hotlinking from a very specific folder in my /data directory. Lets call it /data/sba. Inside /data/sba, I have added an .htaccess file: RewriteEngine on RewriteCond %{HTTP_REFERER} !^$ RewriteCond %{HTTP_REFERER} !^*$ [NC] RewriteRule...