Apache cannot find icons in the grid in the contact_manager.

I am not able to display icons in the grid, or any other dhtmlx component.
I seem to get a 404 error from Apache2. (See the Apache2 access.log snippit below).
I’ve included the apache2 vhost conf files for the dhtmlx demo (where icons are not found)
and for a simple sample site where they are found.

I’ve also included the ls -la output for the site directory.

Any help as to why Apache can not resolve the icons file(s) location would be appreciate.
I tried this on my Development system and I also tried it on a VM running kubuntu 14.04.
Same problem on both.

thanks in advance for your help.

Jeffrey


xxxx@merlin-10:/etc/apache2/sites-enabled$ cat dhtmlx.conf
<VirtualHost *:80>
# The ServerName directive sets the request scheme, hostname and port that
# the server uses to identify itself. This is used when creating
# redirection URLs. In the context of virtual hosts, the ServerName
# specifies what hostname must appear in the request’s Host: header to
# match this virtual host. For the default virtual host (this file) this
# value is not decisive as it is used as a last resort host regardless.
# However, you must set it for any further virtual host explicitly.
#ServerName example.com

    ServerAdmin webmaster@localhost
    DocumentRoot /var/www/dhtmlx

    ServerName dhtmlx
    <Directory /var/www/dhtmlx/>
        AllowOverride All
    </Directory>

    # Available loglevels: trace8, ..., trace1, debug, info, notice, warn,
    # error, crit, alert, emerg.
    # It is also possible to configure the loglevel for particular
    # modules, e.g.
    #LogLevel info ssl:warn

    ErrorLog ${APACHE_LOG_DIR}/error.log
    CustomLog ${APACHE_LOG_DIR}/access.log combined

    # For most configuration files from conf-available/, which are
    # enabled or disabled at a global level, it is possible to
    # include a line for only one particular virtual host. For example the
    # following line enables the CGI configuration for this host only
    # after it has been globally disabled with "a2disconf".
    #Include conf-available/serve-cgi-bin.conf

gtest vhost config

xxxx@merlin-10:/etc/apache2/sites-enabled$ cat gtest.conf
<VirtualHost *:80>
# The ServerName directive sets the request scheme, hostname and port that
# the server uses to identify itself. This is used when creating
# redirection URLs. In the context of virtual hosts, the ServerName
# specifies what hostname must appear in the request’s Host: header to
# match this virtual host. For the default virtual host (this file) this
# value is not decisive as it is used as a last resort host regardless.
# However, you must set it for any further virtual host explicitly.
#ServerName example.com

    ServerAdmin webmaster@localhost
    DocumentRoot /var/www/gtest

    ServerName gtest
    <Directory /var/www/gtest/>
        AllowOverride All
    </Directory>

    # Available loglevels: trace8, ..., trace1, debug, info, notice, warn,
    # error, crit, alert, emerg.
    # It is also possible to configure the loglevel for particular
    # modules, e.g.
    #LogLevel info ssl:warn

    ErrorLog ${APACHE_LOG_DIR}/error.log
    CustomLog ${APACHE_LOG_DIR}/access.log combined

    # For most configuration files from conf-available/, which are
    # enabled or disabled at a global level, it is possible to
    # include a line for only one particular virtual host. For example the
    # following line enables the CGI configuration for this host only
    # after it has been globally disabled with "a2disconf".
    #Include conf-available/serve-cgi-bin.conf

/var/www - links

lrwxrwxrwx 1 root root 53 Aug 28 06:22 dhtmlx -> /home/xxxx/Development/edu/dhtmlx/demos/file_manager
lrwxrwxrwx 1 root root 36 Aug 27 05:01 gtest -> /home/xxxx/Development/edu/gtest-v2

/home/xxxx/Development/edu/dhtmlx/demos/file_manager

drwxrwxr-x 5 xxxx xxxx 4096 Dec 18 2013 .
drwxrwxr-x 4 xxxx xxxx 4096 Aug 28 06:14 …
drwxrwxr-x 4 xxxx xxxx 4096 Oct 15 2013 codebase
drwxrwxr-x 2 xxxx xxxx 4096 Dec 18 2013 data
drwxrwxr-x 2 xxxx xxxx 4096 Dec 5 2013 icons
-rw-rw-r-- 1 xxxx xxxx 3827 Dec 18 2013 index.html

/var/www/dhtmlx/icons

drwxrwxr-x 2 xxxx xxxx 4096 Dec 5 2013 .
drwxrwxr-x 5 xxxx xxxx 4096 Dec 18 2013 …
-rw-rw-r-- 1 xxxx xxxx 1166 Oct 9 2013 add.png
-rw-rw-r-- 1 xxxx xxxx 1197 Oct 9 2013 delete.png
-rw-rw-r-- 1 xxxx xxxx 1340 Oct 9 2013 edit.png
-rw-rw-r-- 1 xxxx xxxx 1276 Oct 22 2013 grid_file1.png
-rw-rw-r-- 1 xxxx xxxx 1961 Oct 22 2013 grid_file2.png
-rw-rw-r-- 1 xxxx xxxx 1368 Oct 22 2013 grid_folder.png
-rw-rw-r-- 1 xxxx xxxx 1362 Oct 9 2013 home.png
-rw-rw-r-- 1 xxxx xxxx 1618 Oct 9 2013 left_arrow.png
-rw-rw-r-- 1 xxxx xxxx 1503 Oct 9 2013 reload.png
-rw-rw-r-- 1 xxxx xxxx 1619 Oct 9 2013 right_arrow.png

Demo address book, failed with 404

127.0.0.1 - - [28/Aug/2015:10:14:24 -0700] “GET / HTTP/1.1” 200 1528 “-” “Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/44.0.2403.157 Safari/537.36”
127.0.0.1 - - [28/Aug/2015:10:14:25 -0700] “GET /codebase/dhtmlx.css HTTP/1.1” 200 22707 “http://dhtmlx/” “Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/44.0.2403.157 Safari/537.36”
127.0.0.1 - - [28/Aug/2015:10:14:25 -0700] “GET /codebase/dhtmlx.js HTTP/1.1” 200 250176 “http://dhtmlx/” “Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/44.0.2403.157 Safari/537.36”
127.0.0.1 - - [28/Aug/2015:10:14:25 -0700] “GET /codebase/imgs/dhxlayout_dhx_terrace/bg_def.gif HTTP/1.1” 304 178 “http://dhtmlx/” “Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/44.0.2403.157 Safari/537.36”
127.0.0.1 - - [28/Aug/2015:10:14:25 -0700] “GET /codebase/imgs/dhxlayout_dhx_terrace/dhxlayout_btns.gif HTTP/1.1” 304 178 “http://dhtmlx/” “Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/44.0.2403.157 Safari/537.36”
127.0.0.1 - - [28/Aug/2015:10:14:25 -0700] “GET /data/toolbarStruct.xml HTTP/1.1” 200 558 “http://dhtmlx/” “Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/44.0.2403.157 Safari/537.36”
127.0.0.1 - - [28/Aug/2015:10:14:25 -0700] “GET /codebase/imgs/sort_desc.gif HTTP/1.1” 304 178 “http://dhtmlx/” “Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/44.0.2403.157 Safari/537.36”
127.0.0.1 - - [28/Aug/2015:10:14:25 -0700] “GET /data/treeStruct.xml HTTP/1.1” 200 532 “http://dhtmlx/” “Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/44.0.2403.157 Safari/537.36”
127.0.0.1 - - [28/Aug/2015:10:14:25 -0700] “GET /icons/left_arrow.png HTTP/1.1” 404 504 “http://dhtmlx/” “Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/44.0.2403.157 Safari/537.36”
127.0.0.1 - - [28/Aug/2015:10:14:25 -0700] “GET /icons/right_arrow.png HTTP/1.1” 404 505 “http://dhtmlx/” “Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/44.0.2403.157 Safari/537.36”
127.0.0.1 - - [28/Aug/2015:10:14:25 -0700] “GET /icons/home.png HTTP/1.1” 404 499 “http://dhtmlx/” “Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/44.0.2403.157 Safari/537.36”
127.0.0.1 - - [28/Aug/2015:10:14:25 -0700] “GET /icons/reload.png HTTP/1.1” 404 501 “http://dhtmlx/” “Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/44.0.2403.157 Safari/537.36”
127.0.0.1 - - [28/Aug/2015:10:14:25 -0700] “GET /icons/add.png HTTP/1.1” 404 498 “http://dhtmlx/” “Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/44.0.2403.157 Safari/537.36”
127.0.0.1 - - [28/Aug/2015:10:14:25 -0700] “GET /icons/edit.png HTTP/1.1” 404 499 “http://dhtmlx/” “Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/44.0.2403.157 Safari/537.36”
127.0.0.1 - - [28/Aug/2015:10:14:25 -0700] “GET /icons/delete.png HTTP/1.1” 404 500 “http://dhtmlx/” “Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/44.0.2403.157 Safari/537.36”
127.0.0.1 - - [28/Aug/2015:10:14:25 -0700] “GET /icons/grid_file1.png HTTP/1.1” 404 504 “http://dhtmlx/” “Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/44.0.2403.157 Safari/537.36”
127.0.0.1 - - [28/Aug/2015:10:14:25 -0700] “GET /icons/grid_folder.png HTTP/1.1” 404 505 “http://dhtmlx/” “Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/44.0.2403.157 Safari/537.36”
127.0.0.1 - - [28/Aug/2015:10:14:25 -0700] “GET /icons/grid_file2.png HTTP/1.1” 404 504 “http://dhtmlx/” “Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/44.0.2403.157 Safari/537.36”
::1 - - [28/Aug/2015:10:14:33 -0700] “OPTIONS * HTTP/1.0” 200 125 “-” “Apache/2.4.7 (Ubuntu) PHP/5.5.9-1ubuntu4.11 (internal dummy connection)”

Test case that worked.

127.0.0.1 - - [28/Aug/2015:10:15:49 -0700] “GET / HTTP/1.1” 200 557 “-” “Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/44.0.2403.157 Safari/537.36”
127.0.0.1 - - [28/Aug/2015:10:15:49 -0700] “GET /resivoir.jpg HTTP/1.1” 304 182 “http://gtest/” “Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/44.0.2403.157 Safari/537.36”

I moved onto the file manager exercise.
Same problem.

I had to stop using the WebStorm debugger in chrome (chrome caches a lot), and I could not get WebStorm to work with Firefox, but the firefox debugger, console works fine…

Sound silly, but I noticed it was an http GET that could not be resolved. I cut and pasted the URL that failed to resolve and started to play with it. To make a long story short: APACHE DOES NOT LIKE THE WORD “icons” anywhere in it’s directory paths. I changed the name to “imgs” and it worked.

Also, the demo had some errors in the path to the theme specific icons. codebase did not like icons, and the skin name in the directory path was missing.

I need to get back to the contact manager, but I did want to share this with other, as it is really weird.
It may Ubunt 14.04 specific, but I’m not about try all permutations…

Jeffrey

Unfortunately the icons for the dhtmlx components should be placed in the “imgs” directory only.