Jess McKenzie

1

votes
0

answer
191

views

Docker Compose file to Docker Stack

I have found an awesome repo that uses docker-compose however I would like to use it Docker Cloud Stacks (I am a newbie). What would I have to do to be able to swap it over? docker-compose: version: '2' services: mariadb: image: wodby/mariadb:10.2-3.0.2 php: # 1. Images with vanilla WordPress – wo...
Jess McKenzie
1

votes
1

answer
75

views

Wordpress Permalinks Overriding .htaccess https and force slash

I am wanting to use the following .htaccess however it works to a point but for me to access the sub pages I have to reset my permalinks and there for this section gets reset. It seems in Wordpress currently there is only plugins to do one or another - not both of my goals. Goals: To force HTTP:// t...
Jess McKenzie
1

votes
2

answer
492

views

.htaccess redirect or PHP change

The main navigation of my site is coded like this: '.$value.''.'\n'; But I would like the URL of the links to look like domain.co.nz/pagename, not domain.co.nz/index.php?pageId=pagename How would you recommend I accomplish this?
Jess McKenzie
1

votes
1

answer
1.1k

views

Pure CSS Sub Dropdown Menu

I am trying to create a menu that has 3 sub menus and I have successfully created the first 2. My issue is with the 3rd drop-down menu, It is only showing one when there is multiple available. CSS /*Reset */ html, body, h1, h2, h3, h4, h5, h6, form, input, ul, ol, p, fieldset, header, footer, sec...
Jess McKenzie
1

votes
1

answer
1.2k

views

Cufon Not Showing

I cannot understand why my Cufon is not working, All .js files load fine: Company Name !window.jQuery && document.write(unescape('%3Cscript src='includes/js/jquery-1.6.min.js'%3E%3C/script%3E')) window.addEvent('domready',function() { Cufon.replace('header h1'); }); Company Home
Jess McKenzie
1

votes
3

answer
462

views

onchange carry selected text and hidden value how?

I have a dynamically populated PHP dropdown menu that gathers the following information from the database: echo ''.$image['description'].''; I then have a javascript function that shows the selected text - description in an input box for editing and then on submit update back into the database. Ques...
Jess McKenzie
1

votes
1

answer
435

views

Align Vertical and Horizontal Align

I am trying to align a box VxH Center but I seem to be getting it just a bit off: HTML: Logo Here CSS: ![#wrapper{ width:955px; margin:auto; } html body{ background:#F1FF29; } #logoWrapper{ width:429px; height:179px; position:absolute; left:50%; top:50%; margin-left:-100px; margin-top:-50px; } .log...
Jess McKenzie
1

votes
1

answer
8.1k

views

Select Box Alignment

How could I align the select box so its inline with the others? I am also trying to do this with the 3 option input boxes. CSS: #newwebsiteSection, #websiteredevelopmentSection, #otherSection{ display:none; } #newwebsiteForm form{ padding:10px; margin:10px 0; width:480px; position: relative; } #new...
Jess McKenzie
1

votes
4

answer
3.7k

views

Form Alignment CSS

This is one thing that I really hate within development is forms. Below is my code and what I am trying to do is align the inputs with the labels Name: input. Is there a rule that you use to help remember when coding forms? CSS: #newwebsiteForm form{ padding:10px; margin:10px 0; width:480px; posit...
Jess McKenzie
1

votes
1

answer
135

views

CSS Layout Improvements

I have the following layout and I would like to know the following: When I have more data how can I make the gray background repeat down the page more? With my portfolio I have margin-left:25px the wrapper but how can I make sure it stops at the end of the content background? CSS: html{ height:100%;...
Jess McKenzie
1

votes
2

answer
986

views

CodeIgniter: Displaying Dynamic Errors

Updated: RJZ: TdjxQetc is the $activateCode that comes from the DB so when I run /confirm/ I should be getting Sorry you did not have a correct Activation Code as I am not passing in any var ($activateCode) but when I run /confirm/$activateCode I should get Thanks your account is now active you may...
Jess McKenzie
1

votes
1

answer
1.8k

views

Codeigniter -> Undefined Variable

I am unsure as too why I am getting the following errors when trying to pass data through to my html email template -> The PHP errors are coming from the view. Undefined variable: companyName -> line 9 Undefined variable: firstName -> line 12 Controller: function _userRegEmail($activateCode,$email,$...
Jess McKenzie
1

votes
1

answer
725

views

HTML5 Canvas Example Screenshots

I have come across html2canvas thanks to a previous question of mine. What I am confused about is how could I implement it to do the following: Create a live thumbnail of a live website. When the live thumbnail is clicked it loads a bigger image of the website. What would be the best way to feed th...
Jess McKenzie
1

votes
1

answer
2k

views

PHP mkdir Permissions

I have tried the following but it seems the folder gets created on the server (cPanel Linux) as 755 and not 777 why? and how could I make it write permission 777 mkdir($location.$folderName, 0777); mkdir($location.$folderName, 777);
Jess McKenzie
1

votes
1

answer
153

views

Navigation li alignment

I am having an issue were I cannot get my 'li' width correct. I have the design I am working off and they look to be about 20px apart to the right with display:inline-block but I cannot seem to get the numbers correct. JS Fiddle HTML: Terms of Use Site Map Privacy Policy Help Company Contact ​ CS...
Jess McKenzie
1

votes
1

answer
264

views

CodeIgniter: Passing information from the Model to the Controller using result_array()

I have the following model that print_r shows Array ( [id] => 1 [cms_name] => Content Mangement System ) Currently in my controller I have $data['contentMangement'] = $this->model->function but I am unsure how to bring my above array into this. function systemOptions($options) { $this->db->selec...
Jess McKenzie
1

votes
2

answer
686

views

Codeigniter Session returning 310 redirect

I have a callback function that checks my login details are correct - If they are wrong it returns an error (this is working fine). If the details are correct it should set the session $this->session->set_userdata('logged_in',TRUE); and then continue with the function login and be redirected to the...
Jess McKenzie
1

votes
1

answer
622

views

array of data in a drop down menu

I am trying to get the area table of my database to display in a drop down menu but I am having trouble because it is an array. In my controller I have: $data['city'] = $this->location->fetchCity(); but in my view when I go I get this Array why? Model: public function fetchCity(){ $this->db->select...
Jess McKenzie
1

votes
2

answer
66

views

PHP MYSQL Configuring a Update Statement

I have the following if statement that works fine for an insert but I cannot seem to get it to only update the table with items that are not inserted: Insert: for($i=0; $i
Jess McKenzie
1

votes
1

answer
1.5k

views

Creating a foreach array from multiple xml elements

I have been trying to create a foreach loop that will get every ListingId from the XML file but for some reason I can only get one 'Id' XML STRUCTURE: PHP: $xml = simplexml_load_file('domain.co.nz/xml.xml'); foreach($xml->List->Listing->ListingId as $value) { $xmlArray[] = $value; }
Jess McKenzie
1

votes
1

answer
279

views

Setting colorbox lightbox ajax href variable

I am currently getting bad request in the colorbox when it pops up: Is there away that I could feed the href using a $ variable? ajaxCall: function ajaxCall(url, data_array, div_id, callback_fn) { var d = ajaxCall(url, data_array, 'rhs_info', 'do_quicklist_actions'); d.done(function(data) {  ...
Jess McKenzie
1

votes
1

answer
61

views

Getting data if one value is NULL

I am having an issue with the code below and my issue is the following: I need to be able to select the shop_shipping_rule_region_code if the country_iso is NULL but I also need to get the $country_iso data as well if present What I am after: The Final Result will have: Overnight UPS NZ Snail Mail...
Jess McKenzie
1

votes
1

answer
796

views

Call to a member function passes() on null

I do have a feeling that I need to use Auth:: or something here to link to passes. Am I correct Issue Line if($validator->passes()) ` getLoginCredentials protected function getLoginCredentials(Request $request) { $validator = $this->loginValidation($request); if($validator->passes()) { return[ 'emai...
Jess McKenzie
1

votes
1

answer
54

views

Updating db field if data is present

I cant seem to get my code working 100%. I am trying to get my code to work in a way like this: if the column value is empty ($id = columnName) then insert into that row. If there is a 'value' found for that $id then update the value already saved in the DB. Function: $socialCheck = SocialSettings...
Jess McKenzie
1

votes
1

answer
29

views

Sub Domain Routes and Controllers

I am new to laravel and I am wondering is there a way to do this? How could I make my subdomain load a specific laravel route/controller?
Jess McKenzie
1

votes
1

answer
675

views

oAuth without user interaction

I am in the process of linking another API with our Cloudbeds API. I am a bit lost with the oAuth for this API as my goal is to somehow interact with Cloudbeds without human interaction as I would run the script via a cron. Is it possible/if so how to have oAuth and userless interaction
Jess McKenzie
1

votes
1

answer
46

views

Table Not Showing Responsive

In my HTML Table below why am I not getting the responsive look even though the class is set? Code: Table Design blockquote p{font-size: 12px;} .removeTop{border-top: none !important;} Term 1 2017 Location Group Day Time Cost Point Chevalier Cruisers Tuesday 10:00 $149.50 Point Chevalier Movers Tues...
Jess McKenzie
1

votes
2

answer
352

views

Traefik not showing IP Address

I am very new to Docker and I am trying to use/configure Docker using docker4wordpress. However I am not getting any IP address for Traefik I should be getting the server public IP address if I am thinking correctly - I am running this on a Linode server. I should then be able to access via porta...
Jess McKenzie
1

votes
1

answer
25

views

Fixed height and width only for desktop

I am trying to implement a Vimeo video however for it to show correctly on mobile etc I have to have it in the responsive share mode however on desktop/notebook etc we want to have it a fixed height and width- how can I do this? Responsive Code: // My own div Learn More
Jess McKenzie
1

votes
1

answer
22

views

jQuery wrap a label with an a href

I have the following structure: Terms & Conditions * I have tried the following however its not appending to the label why? jQuery(document).ready(function( $ ){ $('#nf-field-11').wrapInner(''); });
Jess McKenzie
1

votes
2

answer
52

views

Excluding a value from an array of data

Within my in_array is there away that I can exclude specific terms from $row->guestEmail? For example, @example.com and example1.com are forbidden substrings for the $row->guestEmail values. Here's what I've tried: foreach ($json->data as $row) { if (!in_array($row->guestEmail, $emails) && date('...
Jess McKenzie
1

votes
2

answer
42

views

Foreach loop stripping all data from result

In the code below I have created a blacklist of e-mails that I would like to remove however I am getting an empty array when I run with if(stripos($row->guestEmail, $b)) If I remove the stripos and run with the basic if statement if($row->guestEmail) it shows all of the data including e-mail addres...
Jess McKenzie
1

votes
1

answer
0

views

Function Help -> Organization

I am trying to get the following function to run when the link is clicked and then load the previous page, but I seem to end up with a blank page with no php errors: View:
Jess McKenzie
1

votes
2

answer
0

views

Cannot print data into “view”

I have a page that I would like to show the data from the database. I can print_r($sale) and it shows the data that I am after - $sale is set in the controller but I cannot seem to do it shows nothing. Print_r: Array ( [0] => stdClass Object ( [id] => 48 [name] => Jess McKenzie [location] => Auckl...
Jess McKenzie
1

votes
3

answer
0

views

PHP White Page Controller Issue

I have a section of my code that is causing my whole page to load white with no error message. I have debuged my code and the following section is causing my issue but I cannot work out why: Problem Code: if($this->image_model->updatePage($id, $caption)) { $data['title'] = 'Image Captions'; $data['c...
Jess McKenzie
1

votes
4

answer
0

views

CSS Align Boxes

I have a footer that has 3 columns of content. Currently the css is using float:left. I have tried the following but I just cant get it to align vertical and horizontal. display block display block-inline margin: 0 auto HTML: Information Delivery Information Privacy Policy Terms & Conditions CSS:...
Jess McKenzie
1

votes
1

answer
857

views

New Zealand Phone Form Validation

I am building a form system and I have now started to work on the validation. My framework is CI so for the main part of my validation I have 'trim|required|htmlspecialchars' but what I was wanting to know: A) What would be best to use for url and phone* inputs B) What would you recommend that I us...
Jess McKenzie
1

votes
1

answer
838

views

Codeigniter SHA1 Query

Why is my password not being inserted into the DB Model: function addUser($userData = NULL, $passwordHash) { $this->db->insert('users',$userData,$passwordHash); return TRUE; } Controller: public function addUser() { $data['pageTitle'] = 'GA Add User'; $this->load->view('_assets/header', $data); $thi...
Jess McKenzie
1

votes
2

answer
44

views

Setting url in a constructor function

If I create a constructor function within my class with the variable called $base_url = 'mydomain'. How could I access this via other functions as a general variable? I have tried creating a test function with echo $base_url but it did not return a variable.
Jess McKenzie
1

votes
2

answer
1.7k

views

Fetching Data from var_dump

My var_dump is giving me: object(QueryPath)#2 (7) { ['errTypes':'QueryPath':private]=> int(257) ['document':protected]=> object(DOMDocument)#3 (34) { ['doctype']=> string(22)'(object value omitted)' ['implementation']=> string(22) '(object value omitted)' ['documentElement']=> string(22) '(object va...
Jess McKenzie

View additional