mardi 31 janvier 2017

Can't make SSL certificate work

Can't make SSL certificate work. I bought a SSL sertificate from Comodo using NameCheap. I received two files on email in this format

 www_website_com.ca-bundle
 www_website_com.crt

I have put them in the same directory root where files server.key and server.csr were generated for purchase. After that I restarted Nginx and Gunicorn, but I don't see it work.




Offline (HTML+CSS+PHP) File/Documents Database for local

I created a HTML+CSS+PHP web template. I'm planning to create a offline file/documents database. I'm thinking of a web based or access the files through html.

Functions : Upload file to html and store it to directory/folders.

View Files with different category (for example : ".docs" only) Delete files Add comments/reminders to files Date uploaded Number of days file stored

Is it possible? Or any other way to do it? Adding/ Viewing/Deleting file in a local folder through html/ offline web?




Web Framework with a good Data Structure

I'm used to work with .NET, I'm looking for something like Django, and I was excited to learn it. But I realized that the data structure is a bit weird. The goal is to work with a lot of data and well organized. Where can have a List of a class and do "where", "order by", etc. Like this:

 public partial class Customer : System.Web.UI.Page
 {
     public class myCustomer {
         public String Name {get;set;}
         public int Age { get; set; }
         public String City { get; set; }

         public myCustomer()
         {
         }

         public myCustomer(string _name, int _age, string _city)
         {
             Name = _name;
             Age = _age;
             City = _city;
         }
 }

     List<myCustomer> customerList;

     protected void Page_Load(object sender, EventArgs e)
     {
         customerList = new List<myCustomer>();
         myCustomer co1 = new myCustomer { Name = "Donna", Age = 40, City = "New York" };
         myCustomer co2 = new myCustomer("Raj", 10, "New York");
         myCustomer co3 = new myCustomer("Art", 16, "New York");
         customerList.Add(co1);
         customerList.Add(co2);
         customerList.Add(co3);
         testDataGrid.DataSource = customerList;
         testDataGrid.DataBind();
     }        

}

I'm looking for some framework that can do it, but doesn't .net. Someone know?




calling method outside of form tag in asp.net web forms

i am using some buttons outside of form tag that when clicked need to call method from code behind file. the problem is it doesn't look possible with asp.net web forms as it require everything in form tag so to use code behind file.

my problem is design based . i can't place everything inside form tag . here is my code

        <script src="Scripts/dropzone.js"></script>
        <link href="Content/dropzone.css" rel="stylesheet" />
        <div>
            <div class="fallback">
                <input name="file" type="file" multiple />
            </div>
        </div>

 </asp:Content>

<div style="width:30%;margin:0 auto; padding-top:50px">
    <a class="btn btn-danger btn-lg" id="help" href="#">
        <i class="fa  fa-question"></i> Got Questions
     </a>

    <a class="btn btn-danger btn-lg" href="#" id="validate_Click" style="margin-left:40px;">
        <i class="fa  fa-check-square"></i> Validate
     </a>
</div>

<script>
    $("#help").click(function () {
        swal("Here's a message!");
    });

</script>




How to count how many pages on a web page using python

I am trying to make a program (for practice) that count how many chapters and verses in each book of bible.... So let say if I want to know total chapters or verses in book 1 then it will give me the total number. If I only want to know the number of verse in chapter 4 in book 2 then it only gives me the number of verses in that particular chapter. Also, same for the chapters.

So, my logic was to looks for font class: tk4l (which is unique font size for the body of context) from this web site:

http://ift.tt/2kRSmql

and if it finds the font class then add 1 to my count of chapters and if fails to find the font class move on to the next book ( book += 1 ) and do the same thing..

My question is...

1) how can I print that chapter count?? 2) I have no idea how I should count the number of verses..

I just started to study Python. Please help me on this.. T.T




Browser-sync tool for PHP file

The browser-sync works very well with HTML and CSS. However, it seems that it doesn't work with PHP files. When I click the .php files, the browser tries to download it rather than open it. So, is there a similar tool for PHP development ? Or, are there some configurations I can do to adapt browser-sync to PHP files ?

Thanks for your response.




How to redirect amp content to normal mode

I am totally new here, this is my first question here, recently I have enabled amp option in my site, for some reason I want to disable it. I did this by amp plugin, when I deactivated the plugin all my amp contents ar showing 404 error, one more thing all my contents aren't indexed as amp content, If I deactivate the plugin my amp contents are showing 404 page error, is their any way to redirect my amp contents to normal mode like; http://ift.tt/2jSeJvv and this will redirect to http://ift.tt/2jRW05T in normal mode...please help me here. thanks in advance.




Server-side graphics generation

I'm looking for a library which allows graphics to be generated. I would be able to run a function that plots some points and then draws a graphic which looks something like the picture below.

http://ift.tt/2jRKvsB

I'm developing a web application so it would be great if this could be done without creating a image, however this is not an imperative.




User relevant information in database

i am creating my own web app using java, servlet, apache tomcat and mysql.

The first question is how to organize registration and authorization in the best manner?

The second question is how i should organize my architecture to connect specific user with his data which is stored in db(i mean user can retrieve the data which he added to db)?




GPS Tracker device with internet connection

I want a GPS Tracker Device that can be configured to ping it's current location to some web server after certain time. I googled for it. The one which I got will send it's location via SMS after the calling to it. But I want it to be sent over internet frequently. Please suggest me any device. Thankz in advance.




Twitter widget preview does not work with most keywords

I get "Hmm, an empty timeline. That's weird" as a response whenever I choose a hashtag thats not recommended by the autocomplete in the twitter widget creator.




How to get different applications to share outbound port 80 in apache

I'm trying to have a portal which combines all my applications running on a XAMPP server to only use port 80 for incoming connections.

For example if I'm at McDonald's and would like to login to my many programs which runs on, say, port 60443, and 60444, etc..., but McDonald's wifi blocks all non-port 80 traffic. Which prevents those applications to be accessed. How do I setup apache to behave the way I'd like?

Currently, I have a webpage which loads all the services in an iframe on my main site. Which works on most networks but not all. I'd like to remedy this, preferably using a best practice type setup, I've searched and I've not found any resources on how to go about programming apache to handle this. I'm thinking that this is because I'm not sure what this practice is called.

I would be very grateful if I could get some help on this matter.

Thanks in advance.




403 Forbidden Error You don't have permission to access / on this server. Apache/2.4.23 (Win64)

I've been entering my public ip addressing and hoping it takes me to the content on my web server but I get this error : 403 Forbidden Error You don't have permission to access / on this server. Apache/2.4.23 (Win64)

I've been trying to reconfigure port forwarding settings to remotely access the contents on my WAMP server but to no effect. Perhaps I am doing something wrong in the http.conf file:

#
# This is the main Apache HTTP server configuration file.  It contains the
# configuration directives that give the server its instructions.
# See <URL:http://ift.tt/1a2wb4r; for detailed information.
# In particular, see 
# <URL:http://ift.tt/J7Vxau;
# for a discussion of each configuration directive.
#
# Do NOT simply read the instructions in here without understanding
# what they do.  They're here only as hints or reminders.  If you are unsure
# consult the online docs. You have been warned.  
#
# Configuration and logfile names: If the filenames you specify for many
# of the server's control files begin with "/" (or "drive:/" for Win32), the
# server will use that explicit path.  If the filenames do *not* begin
# with "/", the value of ServerRoot is prepended -- so "logs/access_log"
# with ServerRoot set to "/usr/local/apache2" will be interpreted by the
# server as "/usr/local/apache2/logs/access_log", whereas "/logs/access_log" 
# will be interpreted as '/logs/access_log'.
#
# NOTE: Where filenames are specified, you must use forward slashes
# instead of backslashes (e.g., "c:/apache" instead of "c:\apache").
# If a drive letter is omitted, the drive on which httpd.exe is located
# will be used by default.  It is recommended that you always supply
# an explicit drive letter in absolute paths to avoid confusion.
ServerSignature On
ServerTokens Full

#
# ServerRoot: The top of the directory tree under which the server's
# configuration, error, and log files are kept.
#
# Do not add a slash at the end of the directory path.  If you point
# ServerRoot at a non-local disk, be sure to specify a local disk on the
# Mutex directive, if file-based mutexes are used.  If you wish to share the
# same ServerRoot for multiple httpd daemons, you will need to change at
# least PidFile.
#


# Apache variable names used by Apache conf files:
# The names and contents of variables:
# APACHE24, VERSION_APACHE, INSTALL_DIR, APACHE_DIR
# should never be changed.
Define APACHE24 Apache2.4
Define VERSION_APACHE 2.4.23
Define INSTALL_DIR c:/wamp64
Define APACHE_DIR ${INSTALL_DIR}/bin/apache/apache${VERSION_APACHE}

ServerRoot "${APACHE_DIR}"


#
# Mutex: Allows you to set the mutex mechanism and mutex file directory
# for individual mutexes, or change the global defaults
#
# Uncomment and change the directory if mutexes are file-based and the default
# mutex file directory is not on a local disk or is not appropriate for some
# other reason.
#
# Mutex default:logs

#
# Listen: Allows you to bind Apache to specific IP addresses and/or
# ports, instead of the default. See also the <VirtualHost>
# directive.
#
# Change this to Listen on specific IP addresses as shown below to 
# prevent Apache from glomming onto all bound IP addresses.
#
#Listen 12.34.56.78:80
Listen 80

#
# Dynamic Shared Object (DSO) Support
#
# To be able to use the functionality of a module which was built as a DSO you
# have to place corresponding `LoadModule' lines at this location so the
# directives contained in it are actually available _before_ they are used.
# Statically compiled modules (those listed by `httpd -l') do not need
# to be loaded here.
#
# Example:
# LoadModule foo_module modules/mod_foo.so
#
LoadModule access_compat_module modules/mod_access_compat.so
LoadModule actions_module modules/mod_actions.so
LoadModule alias_module modules/mod_alias.so
LoadModule allowmethods_module modules/mod_allowmethods.so
LoadModule asis_module modules/mod_asis.so
LoadModule auth_basic_module modules/mod_auth_basic.so
LoadModule auth_digest_module modules/mod_auth_digest.so
#LoadModule auth_form_module modules/mod_auth_form.so
#LoadModule authn_anon_module modules/mod_authn_anon.so
LoadModule authn_core_module modules/mod_authn_core.so
#LoadModule authn_dbd_module modules/mod_authn_dbd.so
#LoadModule authn_dbm_module modules/mod_authn_dbm.so
LoadModule authn_file_module modules/mod_authn_file.so
#LoadModule authn_socache_module modules/mod_authn_socache.so
#LoadModule authnz_fcgi_module modules/mod_authnz_fcgi.so
#LoadModule authnz_ldap_module modules/mod_authnz_ldap.so
LoadModule authz_core_module modules/mod_authz_core.so
#LoadModule authz_dbd_module modules/mod_authz_dbd.so
#LoadModule authz_dbm_module modules/mod_authz_dbm.so
LoadModule authz_groupfile_module modules/mod_authz_groupfile.so
LoadModule authz_host_module modules/mod_authz_host.so
#LoadModule authz_owner_module modules/mod_authz_owner.so
LoadModule authz_user_module modules/mod_authz_user.so
LoadModule autoindex_module modules/mod_autoindex.so
#LoadModule buffer_module modules/mod_buffer.so
LoadModule cache_module modules/mod_cache.so
LoadModule cache_disk_module modules/mod_cache_disk.so
#LoadModule cache_socache_module modules/mod_cache_socache.so
#LoadModule cern_meta_module modules/mod_cern_meta.so
LoadModule cgi_module modules/mod_cgi.so
#LoadModule charset_lite_module modules/mod_charset_lite.so
#LoadModule data_module modules/mod_data.so
#LoadModule dav_module modules/mod_dav.so
#LoadModule dav_fs_module modules/mod_dav_fs.so
#LoadModule dav_lock_module modules/mod_dav_lock.so
#LoadModule dbd_module modules/mod_dbd.so
#LoadModule deflate_module modules/mod_deflate.so
LoadModule dir_module modules/mod_dir.so
#LoadModule dumpio_module modules/mod_dumpio.so
LoadModule env_module modules/mod_env.so
#LoadModule expires_module modules/mod_expires.so
#LoadModule ext_filter_module modules/mod_ext_filter.so
LoadModule file_cache_module modules/mod_file_cache.so
#LoadModule filter_module modules/mod_filter.so
#LoadModule http2_module modules/mod_http2.so
#LoadModule headers_module modules/mod_headers.so
#LoadModule heartbeat_module modules/mod_heartbeat.so
#LoadModule heartmonitor_module modules/mod_heartmonitor.so
#LoadModule ident_module modules/mod_ident.so
#LoadModule imagemap_module modules/mod_imagemap.so
LoadModule include_module modules/mod_include.so
#LoadModule info_module modules/mod_info.so
LoadModule isapi_module modules/mod_isapi.so
#LoadModule lbmethod_bybusyness_module modules/mod_lbmethod_bybusyness.so
#LoadModule lbmethod_byrequests_module modules/mod_lbmethod_byrequests.so
#LoadModule lbmethod_bytraffic_module modules/mod_lbmethod_bytraffic.so
#LoadModule lbmethod_heartbeat_module modules/mod_lbmethod_heartbeat.so
#LoadModule ldap_module modules/mod_ldap.so
#LoadModule logio_module modules/mod_logio.so
LoadModule log_config_module modules/mod_log_config.so
#LoadModule log_debug_module modules/mod_log_debug.so
#LoadModule log_forensic_module modules/mod_log_forensic.so
#LoadModule lua_module modules/mod_lua.so
#LoadModule macro_module modules/mod_macro.so
LoadModule mime_module modules/mod_mime.so
#LoadModule mime_magic_module modules/mod_mime_magic.so
LoadModule negotiation_module modules/mod_negotiation.so
#LoadModule proxy_module modules/mod_proxy.so
#LoadModule proxy_ajp_module modules/mod_proxy_ajp.so
#LoadModule proxy_balancer_module modules/mod_proxy_balancer.so
#LoadModule proxy_connect_module modules/mod_proxy_connect.so
#LoadModule proxy_express_module modules/mod_proxy_express.so
#LoadModule proxy_fcgi_module modules/mod_proxy_fcgi.so
#LoadModule proxy_ftp_module modules/mod_proxy_ftp.so
#LoadModule proxy_html_module modules/mod_proxy_html.so
#LoadModule proxy_http_module modules/mod_proxy_http.so
#LoadModule proxy_http2_module modules/mod_proxy_http2.so
#LoadModule proxy_scgi_module modules/mod_proxy_scgi.so
#LoadModule proxy_wstunnel_module modules/mod_proxy_wstunnel.so
#LoadModule ratelimit_module modules/mod_ratelimit.so
#LoadModule reflector_module modules/mod_reflector.so
#LoadModule remoteip_module modules/mod_remoteip.so
#LoadModule request_module modules/mod_request.so
#LoadModule reqtimeout_module modules/mod_reqtimeout.so
LoadModule rewrite_module modules/mod_rewrite.so
#LoadModule sed_module modules/mod_sed.so
#LoadModule session_module modules/mod_session.so
#LoadModule session_cookie_module modules/mod_session_cookie.so
#LoadModule session_crypto_module modules/mod_session_crypto.so
#LoadModule session_dbd_module modules/mod_session_dbd.so
LoadModule setenvif_module modules/mod_setenvif.so
#LoadModule slotmem_plain_module modules/mod_slotmem_plain.so
#LoadModule slotmem_shm_module modules/mod_slotmem_shm.so
#LoadModule socache_dbm_module modules/mod_socache_dbm.so
#LoadModule socache_memcache_module modules/mod_socache_memcache.so
#LoadModule socache_shmcb_module modules/mod_socache_shmcb.so
#LoadModule speling_module modules/mod_speling.so
#LoadModule ssl_module modules/mod_ssl.so
#LoadModule status_module modules/mod_status.so
#LoadModule substitute_module modules/mod_substitute.so
#LoadModule unique_id_module modules/mod_unique_id.so
LoadModule userdir_module modules/mod_userdir.so
#LoadModule usertrack_module modules/mod_usertrack.so
#LoadModule version_module modules/mod_version.so
LoadModule vhost_alias_module modules/mod_vhost_alias.so
#LoadModule watchdog_module modules/mod_watchdog.so
#LoadModule xml2enc_module modules/mod_xml2enc.so

LoadModule php5_module "${INSTALL_DIR}/bin/php/php5.6.25/php5apache2_4.dll"

<IfModule unixd_module>
#
# If you wish httpd to run as a different user or group, you must run
# httpd as root initially and it will switch.  
#
# User/Group: The name (or #number) of the user/group to run httpd as.
# It is usually good practice to create a dedicated user and group for
# running httpd, as with most system services.
#
User daemon
Group daemon

</IfModule>

# 'Main' server configuration
#
# The directives in this section set up the values used by the 'main'
# server, which responds to any requests that aren't handled by a
# <VirtualHost> definition.  These values also provide defaults for
# any <VirtualHost> containers you may define later in the file.
#
# All of these directives may appear inside <VirtualHost> containers,
# in which case these default settings will be overridden for the
# virtual host being defined.
#

#
# ServerAdmin: Your address, where problems with the server should be
# e-mailed.  This address appears on some server-generated pages, such
# as error documents.  e.g. admin@your-domain.com
#
ServerAdmin bkt5031@gmail.com

#
# ServerName gives the name and port that the server uses to identify itself.
# This can often be determined automatically, but we recommend you specify
# it explicitly to prevent problems during startup.
#
# If your host doesn't have a registered DNS name, enter its IP address here.
#
ServerName localhost:80

# Deny access to the entirety of your server's filesystem. You must
# explicitly permit access to web content directories in other 
# <Directory> blocks below.
#
<Directory "C:/wamp64/www/ckbeta/">
    AllowOverride all
    Require all granted
    Order Allow,Deny
    Allow from all

</Directory>

#
# Note that from this point forward you must specifically allow
# particular features to be enabled - so if something's not working as
# you might expect, make sure that you have specifically enabled it
# below.
#
HostnameLookups Off

#
# DocumentRoot: The directory out of which you will serve your
# documents. By default, all requests are taken from this directory, but
# symbolic links and aliases may be used to point to other locations.
#
DocumentRoot "C:/wamp64/www/ckbeta/"
<Directory "C:/wamp64/www/ckbeta/">
    #
    # Possible values for the Options directive are "None", "All",
    # or any combination of:
    #   Indexes Includes FollowSymLinks SymLinksifOwnerMatch ExecCGI MultiViews
    #
    # Note that "MultiViews" must be named *explicitly* --- "Options All"
    # doesn't give it to you.
    #
    # The Options directive is both complicated and important.  Please see
    # http://ift.tt/1a2wcFq
    # for more information.
    #
    Options +Indexes +FollowSymLinks +Multiviews

    #
    # AllowOverride controls what directives may be placed in .htaccess files.
    # It can be "All", "None", or any combination of the keywords:
    #   AllowOverride FileInfo AuthConfig Limit
    #
    AllowOverride all
    Allow from all
    #
    # Controls who can get stuff from this server.
    #

#   onlineoffline tag - don't remove
    Require all granted
</Directory>

#
# DirectoryIndex: sets the file that Apache will serve if a directory
# is requested.
#
<IfModule dir_module>
    DirectoryIndex index.php index.php3 index.html index.htm
</IfModule>

#
# The following lines prevent .htaccess and .htpasswd files from being 
# viewed by Web clients. 
#
<Files ".ht*">
    Require all granted
</Files>

#
# ErrorLog: The location of the error log file.
# If you do not specify an ErrorLog directive within a <VirtualHost>
# container, error messages relating to that virtual host will be
# logged here.  If you *do* define an error logfile for a <VirtualHost>
# container, that host's errors will be logged there and not here.
#
#ErrorLog "logs/error.log"
ErrorLog "${INSTALL_DIR}/logs/apache_error.log"

#
# LogLevel: Control the number of messages logged to the error_log.
# Possible values include: debug, info, notice, warn, error, crit,
# alert, emerg.
#
LogLevel warn

<IfModule log_config_module>
    #
    # The following directives define some format nicknames for use with
    # a CustomLog directive (see below).
    #
    LogFormat "%h %l %u %t \"%r\" %>s %b \"%{Referer}i\" \"%{User-Agent}i\"" combined
    LogFormat "%h %l %u %t \"%r\" %>s %b" common

    <IfModule logio_module>
      # You need to enable mod_logio.c to use %I and %O
      LogFormat "%h %l %u %t \"%r\" %>s %b \"%{Referer}i\" \"%{User-Agent}i\" %I %O" combinedio
    </IfModule>

    #
    # The location and format of the access logfile (Common Logfile Format).
    # If you do not define any access logfiles within a <VirtualHost>
    # container, they will be logged here.  Contrariwise, if you *do*
    # define per-<VirtualHost> access logfiles, transactions will be
    # logged therein and *not* in this file.
    #
    CustomLog "${INSTALL_DIR}/logs/access.log" common
    #
    # If you prefer a logfile with access, agent, and referer information
    # (Combined Logfile Format) you can use the following directive.
    #
    #CustomLog "logs/access.log" combined
</IfModule>

<IfModule alias_module>
    #
    # Redirect: Allows you to tell clients about documents that used to 
    # exist in your server's namespace, but do not anymore. The client 
    # will make a new request for the document at its new location.
    # Example:
    # Redirect permanent /foo http://ift.tt/J7Vvzj

    #
    # Alias: Maps web paths into filesystem paths and is used to
    # access content that does not live under the DocumentRoot.
    # Example:
    # Alias /webpath /full/filesystem/path
    #
    # If you include a trailing / on /webpath then the server will
    # require it to be present in the URL.  You will also likely
    # need to provide a <Directory> section to allow access to
    # the filesystem path.

    #
    # ScriptAlias: This controls which directories contain server scripts. 
    # ScriptAliases are essentially the same as Aliases, except that
    # documents in the target directory are treated as applications and
    # run by the server when requested rather than as documents sent to the
    # client.  The same rules about trailing "/" apply to ScriptAlias
    # directives as to Alias.
    #
    ScriptAlias /cgi-bin/ "${INSTALL_DIR}/cgi-bin/"

</IfModule>

<IfModule cgid_module>
    #
    # ScriptSock: On threaded servers, designate the path to the UNIX
    # socket used to communicate with the CGI daemon of mod_cgid.
    #
    #Scriptsock cgisock
</IfModule>

#
# "c:/Apache24/cgi-bin" should be changed to whatever your ScriptAliased
# CGI directory exists, if you have that configured.
#
<Directory "${INSTALL_DIR}/cgi-bin">
   AllowOverride All
   # Options None
  #  Require all granted
    #   Order Allow,Deny
    #   Allow from all
    #   Allow from 192.168.1.155
    #   Allow from ::80
    #   Allow from localhost
</Directory>

<IfModule mime_module>
    #
    # TypesConfig points to the file containing the list of mappings from
    # filename extension to MIME-type.
    #
    TypesConfig conf/mime.types

    #
    # AddType allows you to add to or override the MIME configuration
    # file specified in TypesConfig for specific file types.
    #
    #AddType application/x-gzip .tgz
    #
    # AddEncoding allows you to have certain browsers uncompress
    # information on the fly. Note: Not all browsers support this.
    #
    AddEncoding x-compress .Z
    AddEncoding x-gzip .gz .tgz
    #
    # If the AddEncoding directives above are commented-out, then you
    # probably should define those extensions to indicate media types:
    #
    AddType application/x-compress .Z
    AddType application/x-gzip .gz .tgz
    AddType application/x-httpd-php .php
    AddType application/x-httpd-php .php3

    #
    # AddHandler allows you to map certain file extensions to "handlers":
    # actions unrelated to filetype. These can be either built into the server
    # or added with the Action directive (see below)
    #
    # To use CGI scripts outside of ScriptAliased directories:
    # (You will also need to add "ExecCGI" to the "Options" directive.)
    #
    #AddHandler cgi-script .cgi

    # For type maps (negotiated resources):
    #AddHandler type-map var

    #
    # Filters allow you to process content before it is sent to the client.
    #
    # To parse .shtml files for server-side includes (SSI):
    # (You will also need to add "Includes" to the "Options" directive.)
    #
    #AddType text/html .shtml
    #AddOutputFilter INCLUDES .shtml
</IfModule>

#
# The mod_mime_magic module allows the server to use various hints from the
# contents of the file itself to determine its type.  The MIMEMagicFile
# directive tells the module where the hint definitions are located.
#
#MIMEMagicFile conf/magic

#
# Customizable error responses come in three flavors:
# 1) plain text 2) local redirects 3) external redirects
#
# Some examples:
#ErrorDocument 500 "The server made a boo boo."
#ErrorDocument 404 /missing.html
#ErrorDocument 404 "/cgi-bin/missing_handler.pl"
#ErrorDocument 402 http://ift.tt/1a2wb4v
#

#
# MaxRanges: Maximum number of Ranges in a request before
# returning the entire resource, or one of the special
# values 'default', 'none' or 'unlimited'.
# Default setting is to accept 200 Ranges.
#MaxRanges unlimited

#
# EnableMMAP and EnableSendfile: On systems that support it, 
# memory-mapping or the sendfile syscall may be used to deliver
# files.  This usually improves server performance, but must
# be turned off when serving from networked-mounted 
# filesystems or if support for these functions is otherwise
# broken on your system.
# Defaults: EnableMMAP On, EnableSendfile Off
#
#EnableMMAP off
EnableSendfile off

# AcceptFilter: On Windows, none uses accept() rather than AcceptEx() and
# will not recycle sockets between connections. This is useful for network
# adapters with broken driver support, as well as some virtual network
# providers such as vpn drivers, or spam, virus or spyware filters.
AcceptFilter http none
AcceptFilter https none

# Supplemental configuration
#
# The configuration files in the conf/extra/ directory can be 
# included to add extra features or to modify the default configuration of 
# the server, or you may simply copy their contents here and change as 
# necessary.

# Server-pool management (MPM specific)
#Include conf/extra/httpd-mpm.conf

# Multi-language error messages
#Include conf/extra/httpd-multilang-errordoc.conf

# Fancy directory listings
Include conf/extra/httpd-autoindex.conf

# Language settings
#Include conf/extra/httpd-languages.conf

# User home directories
#Include conf/extra/httpd-userdir.conf

# Real-time info on requests and configuration
#Include conf/extra/httpd-info.conf

# Virtual hosts
Include conf/extra/httpd-vhosts.conf

# Local access to the Apache HTTP Server Manual
#Include conf/extra/httpd-manual.conf

# Distributed authoring and versioning (WebDAV)
#Include conf/extra/httpd-dav.conf

# Various default settings
#Include conf/extra/httpd-default.conf

# Configure mod_proxy_html to understand HTML4/XHTML1
<IfModule proxy_html_module>
Include conf/extra/proxy-html.conf
</IfModule>

# Secure (SSL/TLS) connections
#Include conf/extra/httpd-ssl.conf
#
# Note: The following must must be present to support
#       starting without SSL on platforms with no /dev/random equivalent
#       but a statically compiled-in mod_ssl.
#
<IfModule ssl_module>
SSLRandomSeed startup builtin
SSLRandomSeed connect builtin
</IfModule>

Include "${INSTALL_DIR}/alias/*"

Am I setting the access permissions wrong?




Integrating GPS for my web site

I'm interested how to integrate GPS modules (I don't know what kind of modules they are), for my website, so that customers could see the location of product. I have to create application, where will be possible to register this modules by managers, and by webpage customers will be able to see the location of this modules. Which fields will do I need, what is required minimum to get GPS information from something, and what tools can I use? I'm a bit new, and will not do this alone, I just want to learn as much as possible until the job starts. Will be glad if you link some internet materials also. I'm looking for them in google, but not sure if doing it in right way.




Detect external extension and notify user

So, I have this web page, and I encountered some extensions that are not 100% compatible with the page. I want to check if they are installed in the user's browser and notify the user that those are not compatible. I know I can't check their local files, and that I cannot access the extension's files unless they are marked as public. So, is there a way to check this sort of things?




Change page URL sent to Universal Google Analytics when using Google Tag Manager

How can I change the page URL that is sent to Universal Google Analytics when using Google Tag Manager? Without Google Tag Manager it's really simple. You just have to add ga('set', 'page', '/my/custom/url'); before ga('send', 'pageview');.

Your Google Analytics script needs to be like this:

<script>
  (function(i,s,o,g,r,a,m){i['GoogleAnalyticsObject']=r;i[r]=i[r]||function(){
  (i[r].q=i[r].q||[]).push(arguments)},i[r].l=1*new Date();a=s.createElement(o),
  m=s.getElementsByTagName(o)[0];a.async=1;a.src=g;m.parentNode.insertBefore(a,m)
  })(window,document,'script','http://ift.tt/1pxBd1V','ga');

      ga('create', 'UA-XXXXXXXX-X', 'auto');
      ga('set', 'page', '/my/custom/url'); /* Set my custom URL */
      ga('send', 'pageview');

</script>

How can I do something similar using Google Tag Manager?




I'm looking for backend MVC Javascript framework suggestions

Server-side Javascript MVC frameworks, what is there?

I'm looking for heavy convention to allow multiple people to work on a project together, quickly. Think Rails, Laravel etc.

I'm not really interested in cobbling something together with Express because the convention/documentation will be instrumental in getting people on their feet asap.

Preferably focussed ES6+ - good focus with generators or async/await would make sync life much easier I think!

I've found Adonis.js that looks very nice, but perhaps a little immature. I'm concerned about missing out on the huge library of community contributed extensions that a more mature framework might enjoy.

Any other recommendations?




Planning to make Website like edmodo.com for thesis/capstone

Hi guys im a mid average programmer, do you think i can make edmodo.com like website i mean i want just a student and professor to have online quizzes like that see their quiz/exam results online example the professor set the quiz or exam for tues @ 10am and will end @ tues @ 6pm like that i will not make look like edmodo i mean i will get some of the features of edmodo have thank you so much for your suggestion i mean i have at least about 3 months to 4 months to do it and i can spend my time for at list 10 to 15hrs day for this project ?

i just want to ask question for the pro here if this project going to be so big ? thank you ^_^




I need help hiding an element when hovering over another non child/parent/sibling element

I'm a beginner when it comes to javascript and I'm trying to write a script to hide a class when I hover over another class. I've written this piece of code however it isn't working as I'd like it to.Could someone give me some pointers as to why this code isn't working and some advice on how to get it to achieve the results I'm looking for.

$(document).ready( function () {
"use strict";
document.getElementsByClassName('nav-bar').onmouseover = function(){

    document.getElementsByClassName('site-title').style.display="none";
};

document.getElementsByClassName('nav-bar').onmouseout = function(){

    document.getElementsByClassName('site-title').style.display="inline";
};

});




Using Semicolons after function declaration (without storing it in a variable which is just a statement), need to minify my js as well

Should i be Using Semicolons after function declaration and by that i don't mean that storing it in variables, I am not talking about statements I am talking about function declaration and if elses, need to minify my js thats why having a having a slight doubt if i should include semi colons as far as i know the syntax I think it shouldnt be just need clarification. Found many other similar questions and stuffs all around the web but all are just focusing on " including them with statements ". I just need verification by some guys who regularly minify their code.




Google Contacts Sync with Database

I couldn't find any documentation on this.

I'm making a web app where the user can sync all of his google contacts with users within the database. (Retrieves all of the users contacts and stores them in the database then retrieves the non imported ones and stores them in their contacts without duplicates.) I've managed to do that part but I can only sync them via database, If I created or delete a user from the database the same is done with the user in the google contacts list.

Is there a way to do it through google contacts?

User DELETES contact from google contact list ---> User DELETED from database.

Thank you.




Clicking on link inside a ifram containing a document VBA

I'm trying to get some data from a site in which the link I want to click on is inside a HTML document, inside an HTML document, inside a ifram.

In the picture below you will see the code displayed with chrome:

Picture of code

Here is the source code

<iframe id=midnav-frame name=midnav src="about:blank" frameborder=0>

So my problem is that i don't know how to make VBA select the links indside the HTML documents. I have done some basic interactions between VBA and HTML before and I have tried everything I know and could find. Below is my last code:

With objIE
.Visible = True
.navigate "http://ift.tt/2kQkTwB"
Do While .Busy Or _
.ReadyState  4
DoEvents
Loop

Set Aftale = .Document.getElementsByName("aftalenr")
Aftale.Item(0).Value = AftaleNummer

Set BrugerId = .Document.getElementsByName("brugernavn")
BrugerId.Item(0).Value = Bruger

Set Adgangskode = .Document.getElementsByName("password")
Adgangskode.Item(0).Value = KODE

.Document.getElementById("edit-submit").Click

Application.Wait (Now + TimeValue("0:00:5"))


.Document.getElementById("midnav-frame").contentDocument.getElementById("leftnav-frame").contentDocument.getElementById("mel3").Click

Hope that you will be able to help me.

Best regards Jacob




WebDavClient (401) Unauthorized WebException

Im working on a solution where i can put data on a server via WebDav, but i keep getting this error:

Excepton

My Authentications on the WebDav server are the following:

Authentication

Im Using this simple Libary: WebDAV.dll 1.0.0 by virtualdreams (i cant post more links) that grants access to the standard Webdav Methods.

In the Authoring Rules i gave access to all content and all users in read, source and write. So would could be the problem?

This is the Method that creates the Exception

    private static void Put()
    {
        Uri uri = new Uri("http://localhost/");

        WebDAVClientCredential cred = new WebDAVClientCredential("", "");
        WebDAVClient client = new WebDAVClient(cred);
        client.Credential.Domain = "administrator";

        client.Put(uri, ObjectToByteArray("test"));
        Console.WriteLine("Uploaded File");
        Console.Read();
    }

I can read and Download Data without a problem.




Open Google Custom Tabs after WebView

everyone Its possible to open google custom tabs in webview. I have a program which with button open webview ( my website ) and i want when the users click a external links in my website this links open with a google custom tab, because webview its too slow but i dont want to show my domain in the coustom tab. Its possible to change webview client with google coustom tabs? This is my question. Thank you!




how to change URL from this to another?

I have a url that is something like forum.mysite.com but want to change that to something else, so the question is how do i change-

forum.mysite.com to http://ift.tt/2kmMQyZ




How can i access phone name and price from IMEI number in my website. Is there any API, or any free database?

I need to build a similar application like snapdeal exchange offer. Which returns the exchange price from an IMEI number. http://ift.tt/2eMWTJc.




Activate button after all required field are filled JSF

How can I set a commandButton as not disabled just after all the required fields of the form are filled correctly? Where should i place the ajax element? and wich event should be triggered?

Required fields are changed dinamically by a selectOneMenu, so i can't know what is the user choise.




What is the format of the new google maps static urls?

I've found this document about the urls

http://ift.tt/2kbG394

I've got this url: http://ift.tt/2jpBH0S

I've come to know 1i and 2i are coordinates but I don't know how to encode my coordinates to be in that format.




JavaScript: screenshot rendered web page Browser style

I assume this question might have been asked before but after hours of searching, I haven't found anything satisfying.

Here's my question: Is it possible to screenshot a fully rendered web page using JavaScript? A little like what most browsers do on windows on the press of ctrl+p.

I have looked into a lot of alternative solutions like html2Canvas.js but none suits my needs. The biggest issue being my web page almost entirely rendered on client side using Javascript. This is also why server side solution like PhantomJS are hardly applicable.

I need the screenshots to be printed as image or PDF. Any idea?

Thanks.




lundi 30 janvier 2017

"How do i fix this issue described below?

Names of places

"I am facing issue,When i enter place name as Mys ; it must display only the name of places starting with Mys,But the Current Behavior is : Apart from the matching city/country it also list few of the unmatched city, like 'Silver Sprint, MD, United States".

How do i fix this issue




dataset is not deleting from php help in code please

<?php

session_start();

?>


<html>
<body>
<?php


require_once 'login.php';
$connection=new mysqli($db_hostname, $db_username, $db_password,$db_database);
if (!$connection) die("unable to connect to mysqli:".mysqli_error());



mysqli_select_db($connection,"dbase1")
or die("db not selected".mysqli_error());


$sql=" SELECT * FROM tab";
$result=$connection->query($sql);


if ($result->num_rows > 0) {

    while($row = $result->fetch_assoc())
    {

?>
<form class="boxed"  style ="border: 4px solid black ; text-align: center; action ="<?php echo $_SERVER['PHP_SELF']; ?>" method="post">

<h1> Message </h1>

<?php


echo "Id:  "   . $row["id"].  "<br>". "Name:  "   . $row["name"].  "<br>". " Email :  "  . $row["email"]. "<br>"."Phone # " . $row["phone"]. "<br>"."Message : " . $row["text"]. "<br>";



?>
<input type="submit" class="button" value="delete" style =" background-color: grey;
    border: none;
    color: white;
    padding: 15px 70px;
    margin: 15px 0px;
    cursor: pointer;"/>



</form> 
<?php



}

}
if(isset($_POST['delete']))
        {
            $id= $_POST($connection,'id');
$sql=" DELETE FROM tab WHERE id=".$id;
$result=$connection->query($sql);


        }


?>

</body>
</html>

This code actually gets data from databse and i want to add a feature if one clicks on delete button the data against that button gets delete for every data set i am making a box with name and more data with delete button all i want is to delete data from db whenever one clicks the delete button and the data against that button i mean a table on that form must need to delete.




Getting traffic from Google Bot Impersonator (Crawler).Is it unsafe?

I am Getting traffic from Google Bot Impersonator (Crawler) on my site.It is increasing day by day.

Is it unsafe or should i block it?




Is any Point Of Sale Available Web based + Android Application with customization?

I am Searching for Open Source Project Point of Sale which is web-Based Backend and front-end with Android Application.

I am getting like the Sqareup POS But it is not customized for android app and also for backend Customization.




Sending mail from website in ASP.NET

I coded a website contact form with mail send and after dozens of research cannot find an answer hoping stackoverflow users can help.

The aspx.cs file signs into the specified gmail configuration to send the email HOWEVER is there a way to set the SENDER as what the user inputs in the email textbox, so instead of recieving the email from myself so when clicking "Reply" on the mailbox its not replying to myself? If that makes sense?

So the sender is not me but the sender is what the user inputs in the mail box and I receive the email FROM the input value rather than myself




Unknown test failed case using mocha, zombie and chai

I'm trying cross-page test using mocha, zombie and chai, following instructions in Web Development with Node & Express.

version info: macOS 10.12.2, mocha 3.5.0, chai 3.2.0, zombie 5.0.5, node v7.4.0.

QA JS Code:

var Browser = require("zombie");
var assert = require("chai").assert;

var browser;

suite("Cross-Page Tests", function () {
    setup(function () {
        browser = new Browser();
    })
    // Test (1
    test("Requesting Group-Rate from the river page, should populate the referrer field", function (done) {
        var referrer = "http://localhost:3000/river";
        browser.visit(referrer, function () {
            browser.clickLink(".requestGroupRate", function () {
                assert(browser.field("referrer").value === referrer);
                done();
            })
        })
    })
    // Test (2
    test("Requesting Group-Rate from the coast page, should populate the referrer field", function (done) {
        var referrer = "http://localhost:3000/coast";
        browser.visit(referrer, function () {
            browser.clickLink(".requestGroupRate", function () {
                assert(browser.field("referrer").value === referrer);
                done();
            })
        })
    })
    // Test (3
    test("Visit request group rate page directly, should have an empty field.", function (done) {
            browser.visit("http://localhost:3000/request-group-rate", function () {
                assert(browser.field("referrer").value === "");
                done();
            })
        })
})

What shows in terminal(after mocha -u tdd -R spec qa/tests-crosspage.js 2>/dev/null ):

...

  1) Cross-Page Tests Requesting Group-Rate from the river page, should populate the referrer field:
     Error: Timeout of 2000ms exceeded. For async tests and hooks, ensure "done()" is called; if returning a Promise, ensure it resolves.


  2) Cross-Page Tests Requesting Group-Rate from the coast page, should populate the referrer field:
     Uncaught AssertionError: No link matching '.requestGroupRate'
      at Browser.clickLink (node_modules/zombie/lib/index.js:695:7)
      at qa/tests-crosspage.js:28:21
      at Browser.done (node_modules/zombie/lib/eventloop.js:589:11)
      at node_modules/zombie/lib/document.js:819:13
      at process._tickCallback (internal/process/next_tick.js:103:7)

  3) Cross-Page Tests Visit request group rate page directly, should have an empty field.:
     Uncaught AssertionError: No link matching '.requestGroupRate'
      at Browser.clickLink (node_modules/zombie/lib/index.js:695:7)
      at qa/tests-crosspage.js:18:21
      at EventLoop.done (node_modules/zombie/lib/eventloop.js:589:11)
      at Immediate.<anonymous> (node_modules/zombie/lib/eventloop.js:688:71)

What makes me confused: 1) I called done() in every test, but why test 1 still get time exceeded? 2) In test 3, there's no code related to link matching '.requestGroupRate', so where does it come?

Note: I've checked the localhost:3000\river page manually. There is a <a> with class of requestGroupRate. The coast page doesn't exist, so the test 2 is a must-fail test.




Dynamically Loading Local Images with ReactJS

I'm trying to render several images from an array, passed onto an "Image" component as a property. However, for whatever reason, the local images I would like to render are not showing up. If I load an image hosted at a web address, that image will show up, indicating that there is nothing wrong with the "imageSource" property being passed onto the Image component. I have tried playing with the source format like so:

let source = 'require(./img/' + props.imageSource + ")";

or trying:

<img src= role="presentation" style={style.image} />

...but nothing I do makes any difference.

The component is as seen below. I am totally stuck, so help would be much appreciated!

import React from 'react';

let Image = function statelessFunctionComponentClass(props) {

  let source = './img/' + props.imageSource;

  const style = {

    image : {

      width: '400pt',
      height: '400pt'
    }
  }

  return (

    <img src={source} role="presentation" style={style.image} />
  )
}

export default Image




Fire a specific SQL Query depending on the dropbox at the same page made using Bootstrap

Well, I have a bootstrap Dropbox on this page and depending on the value selected I need to fire the SQL Query and only list down students of that particular batch.

//THE DROPBOX CODE

       <tr>
                        <td>
                          <h5>'.$subject_name[$i].'</h5>
                        </td>
                        <td>0</td>
                        <td>
                          <div class="dropdown">
                            <a class="dropdown-toggle" data-toggle="dropdown">
                            <span id="'.$j.'" class="abc">Theory</span>
                            <span class="caret"></span></a>
                            <ul class="dropdown-menu '.$j.'"" onclick="drop(event);">
                              <li select value="theory"><a href="#">Theory</a></li>
                              <li class="divider"></li>
                              <li value="Practical A"><a href="#">Practical - A</a></li>
                              <li value="Practical B"><a href="#">Practical - B</a></li>
                              <li value="Practical C"><a href="#">Practical - C</a></li>
                              <li class="divider"></li>
                              <li value="Elective PCD"><a href="#">Electives - PCD</a></li>
                              <li value="Elective OR"><a href="#">Electives - OR</a></li>
                              <li value="Elective HCI"><a href="#">Electives - HCI</a></li>
                            </ul>
                          </div>
                            <script>
                                $(".'.$j.' a").click(function(){
                                 $("#'.$j.'").text($(this).text());
                                 });
                            </script>
                              </td>
                              <td>
                                <button type="button" class="btn btn-primary btn-sm" data-toggle="modal" data-target="#myModal">
                                  Mark attendance
                                </button>
                              </td>
                            </tr>

//THE PHP CODE

http://ift.tt/2k9DF2K




how to redirect (proxy) all requests for certain users

This might be the case of trying to be too clever. My overall goal is to create test accounts that I can use in production for our iOS app that speaks to an API (Node.js/Express). Eg: Think along these lines

if (isTestAccount(req.user)) return goToStagingServer(res)

Therefore, rather than pointing all requests in our TestFlight® to the staging API, I'd like to keep that (generally speaking) to the production API, and only re-route (talk to) Staging for certain users. Any ideas?




How to develop a plugin for a web application ASP.Net Webforms?

I looking to develop a plugin which has not only the functionality or business rules but also the user interface embed to the dlls.

The idea is to reference the dll to any web application and that module gets added automatically using global.asax without having to change any code. Is it possible in web forms?




Why sqlsrv donest work on godaddy [on hold]

I'm coding a web site in which I need to use a BD in a different server not in my godaddy server. They thing is that the first BD is an sql and my second (in godaddy) is mysql. When I test my code it says something about sqlsrv. I found some info about it and says about mssql. I changed the extension to mssql and the message didnt appear anymore but it doesnt display any info.

So, if anyone knows how to use sqlsrv on godaddy please let me know




php PDO prepared statements binding and returning as json [duplicate]

This question already has an answer here:

I try to make a prepared statement, bind parameter and execute it on my pdo, however when I run the script in my jquery, json return value is null array

  $tableName='cd';  
   $result = $db->prepare('SELECT * FROM :name');
    $result->bindParam(':name',$tableName,PDO::PARAM_STR);
    $result->execute();
    $data = $result->fetchAll(PDO::FETCH_ASSOC);
    echo json_encode($data);

However, when i run the query with 'SELECT * FROM cd' instead of :name it works perfectly fine. Whan can be the reason it does not work?




Can I use the same php web socket server for both web application and mobile application

I have a php websocket code which i used to serve a web application via javascript, how can i use this same codebase to serve a mobile application? do I need a separate web socket for mobile application?




chrome and bluetooth - connecting, discovering - how to make it working?

I am working on project that would discover nearby bluetooth devices via webpage.

Here are my limitations: - development under windows 7 or 10, android 5 on phone - peripheral is bluetooth beacon - central is phone with android 6

First of all i made a page looking like this:

<html>
<head>
  <script src="jquery-3.1.1.js"></script>
</head>
<body>

<div id="target" style="width: 100px; height: 100px; border: 1px solid red"></div>

<script>
$('#target').click(function() { 
  chrome.bluetooth.startDiscovery(function () { 
  navigator.bluetooth.requestDevice({ filters: [{ services:['battery_service'] }] })
  .then(device => {

    console.log(device);
  return device.gatt.connect();
  }).then(server => { console.log(server)}).catch(error  => { console.log(error); });
})
</script>
</body>
</html>

This piece of code lets me to pair bluetooth device with service called "battery_service" with webpage. And it is working (morover) - it opens "chrome system" window for searching nearby devices and finds one if only i have already paired it in windows. If it wasnt paired earlier it will find nothing. Chrome says that gatt server doesnt exist so i can not connect it, and object has gatt property that has gatt property that has gatt property (and so on to the infinity)

Anyways it returns device object containing device.name and device.id property. Other properties are undefined.

None of any examples i found on internet have been working for me.

So here are questions:

  1. is it possible to use windows as development platform?
  2. is it possible to use android 5 to be bluetooth perpiheral?
  3. what is the difference between chrome.bluetooth object and navigator.bluetooth object? Every tutorial uses chrome.bluetooth however it is undefined object in my chrome browser. Navigator.bluetooth works as mentioned before.
  4. i've found chrome.bluetooth.startDiscovery but navigator.bluetooth doesnt have such method, and chrome.bluetooth is empty object i can not discover it at all. Because i do not want even to connect to devices, but only know its presence is it possible not to pair the devices each time it comes into the bluetooth range?
  5. are there any working examples?
  6. should be windows pairing enough? Do we need for security reasons pair devices in chrome that are already paired by operating system?

I use CHROME 56.0.2924.76 64bit.

Thanks for any help! Kalreg




How to temporary replace the main-scroll with inner div scroll

My landing page

this page is contains of main sroll that will scroll whole page and section scroll 1 that will scroll section 1, in this case, the main scroll will stop scrolling when reach section 1 and will continue after section 1 finish scrolled. it means, main scroll will temporary replaced by section 1 scroll when section 1 is on the top of the window, can anybody help me to fix this?? I recently found sticky-kit by leafo but I think this plugin cant resolve this problem




(JavaScript]) Regex pattern if string contains characters

Sorry for being an absolute beginner, when it comes to Javascript and Regex,

I have a Codepen: http://ift.tt/2jJ4XhQ

What I want to accomplish is to validate, if a String contains some special UTF-8 characters. That's why I work with RegExp. The pattern I have here will return false only if the string to test equals one of the characters. But I want to return false if it contains one of these characters.

How can I accomplish this, I know it should be quite easy, but I wasn't able to get it working.

var regEx = new RegExp('[\u0001-\u00FF]');

console.log("This should be true: " + regEx.test("Tes"));
console.log("This should be false: " + regEx.test("Tes�"));

console.log("This returns false, because the string equals a special character: " + regEx.test("�"));



dimanche 29 janvier 2017

I have this issue when ever i tried to open my application

Error 500--Internal Server Error javax.servlet.ServletException: [HTTP:101249][ServletContext@423027198[app:CoalNetPRODHQ module:CoalNetPRODHQ path:/CoalNetPRODHQ spec-version:2.5]]: Servlet class jsp_servlet._common._jsp.__login for servlet /common/jsp/login.jsp could not be loaded because the requested class was not found in the classpath . java.lang.ClassNotFoundException: jsp_servlet._common._jsp.__login. at weblogic.servlet.internal.ServletStubImpl.prepareServlet(ServletStubImpl.java:551) at weblogic.servlet.jsp.JspStub.prepareServlet(JspStub.java:281) at weblogic.servlet.jsp.JspStub.prepareServlet(JspStub.java:216) at weblogic.servlet.internal.ServletStubImpl.execute(ServletStubImpl.java:244) at weblogic.servlet.internal.TailFilter.doFilter(TailFilter.java:26) at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:56) at oracle.security.jps.ee.http.JpsAbsFilter$1.run(JpsAbsFilter.java:119) at java.security.AccessController.doPrivileged(Native Method) at oracle.security.jps.util.JpsSubject.doAsPrivileged(JpsSubject.java:324) at oracle.security.jps.ee.util.JpsPlatformUtil.runJaasMode(JpsPlatformUtil.java:460) at oracle.security.jps.ee.http.JpsAbsFilter.runJaasMode(JpsAbsFilter.java:103) at oracle.security.jps.ee.http.JpsAbsFilter.doFilter(JpsAbsFilter.java:171) at oracle.security.jps.ee.http.JpsFilter.doFilter(JpsFilter.java:71) at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:56) at oracle.dms.servlet.DMSServletFilter.doFilter(DMSServletFilter.java:163) at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:56) at weblogic.servlet.internal.WebAppServletContext$ServletInvocationAction.wrapRun(WebAppServletContext.java:3730) at weblogic.servlet.internal.WebAppServletContext$ServletInvocationAction.run(WebAppServletContext.java:3696) at weblogic.security.acl.internal.AuthenticatedSubject.doAs(AuthenticatedSubject.java:321) at weblogic.security.service.SecurityManager.runAs(SecurityManager.java:120) at weblogic.servlet.internal.WebAppServletContext.securedExecute(WebAppServletContext.java:2273) at weblogic.servlet.internal.WebAppServletContext.execute(WebAppServletContext.java:2179) at weblogic.servlet.internal.ServletRequestImpl.run(ServletRequestImpl.java:1490) at weblogic.work.ExecuteThread.execute(ExecuteThread.java:256) at weblogic.work.ExecuteThread.run(ExecuteThread.java:221)

Here is my web.xml file

<?xml version="1.0"?>
<!DOCTYPE web-app PUBLIC "-//Sun Microsystems, Inc.//DTD Web Application      2.2//EN" "http://ift.tt/1kXu4dj">

<web-app>
<display-name>CoalNet Systems</display-name>
<description>A small demo web-app demonstrating
    interaction between JSP and EJB.</description>
<welcome-file-list>
    <welcome-file>coalnet.jsp</welcome-file>
    <!--<welcome-file>common/html/menu1.html</welcome-file>-->
</welcome-file-list>
<session-config>
<session-timeout>15</session-timeout>
  </session-config>
</web-app>




How to configure nginx rewrite rules for fuelphp framework?

Ive faced this problem when trying to execute an action from a controller in fuelphp framework, I get an 404 message from nginx. Im able to see, for e.g. localhost/index.php or just localhost, but when I try to access to an action-controller like localhost/http://ift.tt/2jtEWQn I get the 404 error. Can anyone help me? this app is currently working in apache, I was facing this trouble here too but everything got fine when I executed

a2enmod rewrite

then I tried to search for equivalent config for nginx and I found this like:

location /{ try_files $uri $uri/ /index.php?$args /index.php?q=$request_uri }

or this:

location /{
rewrite ^ /index.php?/$request_uri;}

but they didnt work for me. Ive spent several hours trying to find out the reason. This is my actual vhost file config for my site:

server {
        listen 80;
        listen [::]:80;
        root /var/www/nginx/goutmeet;
        index index.php index.html index.htm index.nginx-debian.html;

        server_name goutmeet.local www.goutmeet.local;

        location / {
        try_files $uri $uri/ /index.php?$args  /index.php?q=$request_uri @handler;
        }
 location ~ \.php$ {
                include snippets/fastcgi-php.conf;
                fastcgi_pass unix:/run/php/php7.0-fpm.sock;
        }
location @handler {
                rewrite ^ /index.php?/$request_uri;
        }
}

Id love to know how to solve this since using nginx sometimes is a better option than apache, and having this issue with fuelphp framework and not being able to use this two great tools together is awful. Thanks in advance.




Website and google drive?

I am learning web devlopment (ruby on rails / php) and my objective is to develop a website like coursera or edx. I have to store many files (pdf or jpeg) which will be post by users and my problem now is to know if i can store them in my google drive or yahoo cloud storage (mail with 1 To of space), and display the file on the website when a user want to read it. Anyone can help ??




how to print variables from html5 page on flask ?

<div>Product Latitude =  <span id="lati"></span></div>
<div>Product Longitude = <span id="long"></span></div>
<div>Accuracy =  <span id="accu"></span></div>

I want to print them in flask simply or what if i need this information in csv format using flask.




Testing File Updates and Improvements without showing to users

I'm pretty new to web development and as I build websites using an Apache server, I was wondering how to prototype changes. For example, say I'm working on improving a PHP file that is already being displayed on the site. How can I test whether the changes I'm implementing work when the updated file is put on the server without disrupting users to the site if there is an error in the new code?




BXSlider - how to make iamge fill the slider

I am developing a web app where I used BXSlider to show an image slide show on top of the page. The problem I have is the images does not fit into the slider. It shows white margins around the images. How to make the image fill the silder ?




How do we print a counter from a servlet to a jsp?

Hey I am trying to create a voting app.

I have several counters in my servlets and I want to be able to display the value of those counters in my jsp file. How do I do it? Please help me. I want to display the total number of votes in each section and the winner after the election. ...................................................................................................................................................... servlet file ......................................................................................................................................................

    import java.io.IOException;
    import javax.servlet.ServletException;
    import javax.servlet.annotation.WebServlet;
    import javax.servlet.http.HttpServlet;
    import javax.servlet.http.HttpServletRequest;
    import javax.servlet.http.HttpServletResponse;

    @WebServlet("/CastVote")
    public class CastVote extends HttpServlet {
        int javaCount, phpCount, pythonCount, othersCount;

        public CastVote() {
            super();

            javaCount = 0;
            phpCount = 0;
            pythonCount = 0;
            othersCount = 0;  
            // TODO Auto-generated constructor stub
        }

        protected void doPost(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException {
            String choice = request.getParameter("language");

            if("java".equals(choice))
            {
                javaCount++;
            }

            else if("php".equals(choice))
            {
                phpCount++;
            }

            else if("python".equals(choice))
            {
                pythonCount++;
            }

            else if("others".equals(choice))
            {
                othersCount++;
            }

        }

    }

...................................................................................................................................................... Jsp File ......................................................................................................................................................

    <%@ page language="java" contentType="text/html; charset=UTF-8"
        pageEncoding="UTF-8"%>
    <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://ift.tt/kTyqzh">
    <html>
    <head>
    <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
    <title>Vote now.</title>
    </head>
    <body>

        <center>
            <h2>Welcome to voting portal. Cast your vote.</h2>
        </center>
        <form action="CastVote" method="post">
            Which of the following is the best language for backend programming? <br>
            <input type="radio" name="language" value="java">1) Java <br>
            <input type="radio" name="language" value="php">2) PHP <br>
            <input type="radio" name="language" value="python">3)        Python <br>
            <input type="radio" name="language" value="others">4) Others <br>
            <input type = "submit" value ="Vote">
        </form>


    </body>
    </html>




On click web view android asks new browser instead of same,

On click web view android asks new browser instead of same, i am new to android app

public class MainActivity extends AppCompatActivity {

private static final String TOAST_TEXT = "Welcome "
        + "To my site.";




protected void onCreate(Bundle savedInstanceState) {
    super.onCreate(savedInstanceState);
    setContentView(R.layout.activity_main);

    String url ="http://ift.tt/2jjGFML";
    WebView View=(WebView) this.findViewById(R.id.WebView);
    View.getSettings ().setJavaScriptEnabled(true);
    View.loadUrl(url);




Where to store assets for multiple web apps

I am working on a project that is consisted of multiple web applications communicating through some messaging system. Those applications need to be looking at some assets like images and so. Is storing images in MySQL database as blobs a good idea? or should I be using another tool.

Notes:

  • I cannot use a hosting server because it's not guaranteed to have internet connection where the applications are deployed. Thank you.

  • Applications are to be deployed on different machines.




What are popular media-storing service application?

I am in a search for open source media server application, controllable by JSON API. I expect the following features:

  1. Uploading and storing large audio files, auto-detecting media formats
  2. Providing a key (e.g. a permanent link) to control the stored media
  3. Retrieving the fragment of stored media given its start/stop time

The goal is to integrate such a service into a Web application. Could you suggest popular solutions in this area? The minimal software dependencies (python, PHP, etc) would be a bonus.




database frontend

I would need some support/recommendation. What I would like to create is a web frontend for potential customer requests. Customer can login and add certain information + add description, images (!).

All should be stored in a database which I/my colleagues can access through a web interface.

I would like to have 2 views: 1. Table with all database input information + picture thumbnail 2. Once I click on an element I can see the detailed view with same/additional data from the database + full size image.

Is there anything available like a wysiwyg editor for databases? Python would be ideal for me, if I have to program/modify something.

Thanks in advance for your help!




Webview scaleToFitPage doesn't scale page to fit in the webView

I am building a simple iOS application in Swift which is built with a webView inside the view. When load a Motion jpeg (mjpeg) in the webView and set

     let reqObj = URLRequest(url: url! as URL)         
     vidView.delegate = self
     vidView.scalesPageToFit = true
     vidView.loadRequest(reqObj)

the pages load as I want in the right scale but after 1-2seconds the web view zooms in without any reason??? It seems to work but goes back and fourth between the scale I want and the zoomed in scale that i down want. I have read that one can set something to the html meta but don't understand how if this is the problem???

This is what I want it to be like but this is what It goes to after a few seconds This is what I don't want it to be like

The web view goes between these 2 content the whole time

Please if someone could help me with this matter and maybe knows what the problem is.




Android getting website content using InputStream

I am trying to get the content of a website (its source) in an Android app.

URL url = new URL("http://verbmaps.com/");
URLConnection con = url.openConnection();
con.setRequestProperty("User-Agent", "Mozilla/5.0");
InputStream is = con.getInputStream();

Now this gives a lot of errors when run.

(I have put this is a js snippet so I could hide it)

/*

W/System.err: android.os.NetworkOnMainThreadException
W/System.err:     at android.os.StrictMode$AndroidBlockGuardPolicy.onNetwork(StrictMode.java:1273)
W/System.err:     at java.net.InetAddress.lookupHostByName(InetAddress.java:431)
W/System.err:     at java.net.InetAddress.getAllByNameImpl(InetAddress.java:252)
W/System.err:     at java.net.InetAddress.getAllByName(InetAddress.java:215)
W/System.err:     at com.android.okhttp.internal.Network$1.resolveInetAddresses(Network.java:29)
W/System.err:     at com.android.okhttp.internal.http.RouteSelector.resetNextInetSocketAddress(RouteSelector.java:188)
W/System.err:     at com.android.okhttp.internal.http.RouteSelector.nextProxy(RouteSelector.java:157)
W/System.err:     at com.android.okhttp.internal.http.RouteSelector.next(RouteSelector.java:100)
W/System.err:     at com.android.okhttp.internal.http.HttpEngine.createNextConnection(HttpEngine.java:357)
W/System.err:     at com.android.okhttp.internal.http.HttpEngine.nextConnection(HttpEngine.java:340)
W/System.err:     at com.android.okhttp.internal.http.HttpEngine.connect(HttpEngine.java:330)
W/System.err:     at com.android.okhttp.internal.http.HttpEngine.sendRequest(HttpEngine.java:248)
W/System.err:     at com.android.okhttp.internal.huc.HttpURLConnectionImpl.execute(HttpURLConnectionImpl.java:433)
W/System.err:     at com.android.okhttp.internal.huc.HttpURLConnectionImpl.getResponse(HttpURLConnectionImpl.java:384)
W/System.err:     at com.android.okhttp.internal.huc.HttpURLConnectionImpl.getInputStream(HttpURLConnectionImpl.java:231)
W/System.err:     at com.example.yeeverbs.MainActivity$override.onCreate(MainActivity.java:41)
W/System.err:     at com.example.yeeverbs.MainActivity$override.access$dispatch(MainActivity.java)
W/System.err:     at com.example.yeeverbs.MainActivity.onCreate(MainActivity.java:0)
W/System.err:     at android.app.Activity.performCreate(Activity.java:6237)
W/System.err:     at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1107)
W/System.err:     at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2369)
W/System.err:     at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2476)
W/System.err:     at android.app.ActivityThread.handleRelaunchActivity(ActivityThread.java:4077)
W/System.err:     at android.app.ActivityThread.-wrap15(ActivityThread.java)
W/System.err:     at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1350)
W/System.err:     at android.os.Handler.dispatchMessage(Handler.java:102)
W/System.err:     at android.os.Looper.loop(Looper.java:148)
W/System.err:     at android.app.ActivityThread.main(ActivityThread.java:5417)
W/System.err:     at java.lang.reflect.Method.invoke(Native Method)
W/System.err:     at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:726)
W/System.err:     at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:616)


*/

One of the errors points to line 41, which is the line with the InputStream:

InputStream is = con.getInputStream();

Hence, I was not able to run it successfully.

Additional Notes

I have the required permissions in my Android Manifest file

<uses-permission android:name="android.permission.INTERNET" />
<uses-permission android:name="android.permission.ACCESS_NETWORK_STATE"/>

Also I've seen that several solutions use DefaultHttpClient instead of URL. I tried it out, but Android Studio tells me it is deprecated. So I had to go back to using URL unless there are any other better alternatives that are not deprecated.

Additionally, I'm trying to do this without any external libraries, so I am not going to accept JSoup or any other such libraries.

In short,

I am getting the source of a website using URL. However InputStream is giving me errors.

I want to know why this is happening. Also any better alternatives that are not deprecated or are external libraries to this task will be appreciated.




Raspberry Pi Python - Water Level Indicator

I have a Raspberry Pi that is connected to the breadboard. I'm using a BC548 NPN transistor. I want to know what will I code if the wire(color green) touches the water and the LED will turn on. Below also is my sample code and the comment explains all.

Circuit click here

I'm using flask to have a web server. This is my code:

import RPi.GPIO as GIO
from flast import Flask

GPIO.setmode(GPIO.BOARD)
GPIO.setup(12,GPIO.OUT)
GPIO.output(12,GPOO.LOW)     //resets the led

app = Flast(__name__)
@app.route('/')
def index():
    return 'Hello'
    // i want to add code if(wire touches the water) then led will turn on and print('wire touches water')

if __name__ == '__mnain__':
    app.run(debug=True, host='0.0.0.0')

GPIO.cleanup()

I want to add something like if (wire touches water) then GPIO.output(12, 1) and print('wire touches water'). How can I do this?

Sorry I'm new to the Python language same as the Raspberry Pi. doing this for my project. My main language is Java. But I can learn the syntax of it. Thank you.




Is ajax is the only web development technique to get data asynchronously from the web?

I have been studying ajax for a while now and its comes to my mind "Is ajax is the only web development technique to get data asynchronously from the web?".

I searched quite a lot in google but i cant any specifics on the same.




samedi 28 janvier 2017

Using a sprite object with Phaser?

I am realllly new to game development, and even newer to phaser. I just discovered the library when I needed to find a way to build my game background. Im building a web based game in javascript. Ive already written all of the code for my game to animate/control the sprites, so I dont want to throw away that code since it works perfectly for what i want. I have my own gameengine, assetmanager etc. What my question was, is that is there a way to use my existing code with phaser? For instance, when I want to add my sprite onto my map, you have to call:

       this.player = this.game.add.sprite(100, 300, 'player');

'player' is a tag that refers to the .png file. I want to be able to add my sprite that i have already animated, which is also controlled by keys. Is there a way to do this? Is there a method in the Phaser api that allows this? Or is there a better way to render my JSON data for my tile map? I find that phaser makes everything really easy for you, but i really just want to render my background using it, and be able to add my sprites/collisions on it using the api. I am really new to this, so any advice would be great! Thanks!




Meet Error when run Spring MVC web application, " Servlet [mvc-dispatcher] in web application threw load() exception java.lang.ClassNotFoundException"

Hello I was trying to build a simple spring MVC project but when I am running my code I am getting: Hello I am new to spring and I was trying to build a simple spring MVC project but when I am running my code I am getting: Servlet [mvc-dispatcher] in web application threw load() exception java.lang.ClassNotFoundException

I run it in Eclipse + TomCAt 9.0




Where can I host my web application for free?

I have a web application that uses PHP and AngularJs. So I tried google appengine but somehow it just isn't cooperating with me. I've deployed projects (that dont use Angular) onto Heroku with success. However i find that Angular and heroku doesn't play well together for some reason. I coded my web application with Netbeans but when i try to deploying to AppEngine and Heroku, it just doesn't work out.

Does anybody know where I can host my web application for free?

I get that sometimes these things are tricky and I may have missed a step for deployment, any information is greatly appreciated.




Automatic search in a page

I'm doing a little program to analyze a lottery result. This lottery have, today, 1467 results and they are all public. I can see them on this link. But, I don't wanna manually search each result and copy the result to my program (its possible, but will take a lot of my time), so, i start to think about to do this with some JS. But i don't work with JS, and researching about search field on JS i saw that browsers have the Same-origin Policy. Inspecting the html I saw the Previous button (named: "Anterior"). So, it is possible to do a while/for and use this button to automatically get all the pages with the results or I really need to go one by one by myself? I saw this similar question here, but I don't know how to adapt this to my case. Thanks!




web server - how to choose backend language

I am confused about web servers.

Until now I have only learned HTML, CSS and Javascript, and as far as I know these can "run" on any kind of paid web server.

Now I want to learn some "backend" language, but I am confused what exactly can be runned on web server. And by web server I do not mean my own, but paid preconfigured web server.

So I have following situation:

I have paid for web server ( long ago, before I considered to make anything else than simple web pages ) and in description I can see that it offers :

  • PHP
  • Python
  • MySql
  • Perl

I think it is linux apache server ( I do not know much about this so I apologies If I stated something wrong ).

Could this web server run .aspx sites ( programmed in C# ) ? If it is possible can it be managed by me or does hosting company has to approve it ( by configuring it for me ? ). Or can on this site be installed node.js as backend ? What about Python Django ?

So basically my question is, if I choose xxx language/framework/whatever do I have to choose web server accordingly or I can use whatever hosting company I like ?




how to backup Joomla website when developing on MAMP?

I am a new web developer. I have been using Joomla with a 3rd party template, developing it on a local MAMP server. The template is sort of unstable and breaks easily. I would like to Backup my work on a daily basis.

I'm assuming all the files and the database need to be backed-up? Is there a best practice for this?

Thanks very much!




Is it possible to integrate Google Maps to the Facebook app?

I did a extensive research about intergrading Google Maps SDK to the Facebook App. I couldn't find anything. Please direct me to correct source how to do that ? Is it possible ?




Unable to position text

I center-aligned some text and then positioned it using top:20%. It worked fine, but when I added a paragraph under it, the element just moved back into the beginning position(the top:20% didn't take effect).

    <style>
    .yes{
            width : 100%;
            height : 50%;
            background-color: red;
            text-align: center;
        }
        .yes a{
            font-size : 300%;
            position: relative;
            top : 20%;
        }
    </style>

    <div class = "yes">
    <a>Title</a>
    <p></p></div>




What does this PHP script do?

I just found this "encrypted" malicious php script on my school's web server. I "decrypted" it by replacing eval(...) with echo(...) (at the end of the script). It sends spam to email adresses, which are transmitted via post. Unfortunately these post request are "encrypted" to. Could the script potentially reveal any information about the attacker? I would appreciate a modified script, which logs the recipient and the content of the emails.




Service worker update delay

I have a web app that is working and relying on service workers to keep all the cached files in check and to make sure users are on the correct version of the app.

Our client is currently wanting the device to check for an update at specific points (When reopening the app) etc, as currently when you open the app it can take up to 5minutes before the device realises its on an outdated version.

Am I able to force the device to check the service worker for any new changes instead of waiting for the app to check for me?

Thanks!




Free Image databse, behind website

I am working on a University project. I have developed a test harness, one of the features of the test harness is visual regression testing.

I am developing a basic website, as a means to displays these generated images programmatically.

My original idea was to use a mongodb database, however after some reading many people advise not using mongodb to store images.

I then tried to use google drive and drop box, however they do not facilitate permanent url's to the stored images. Or in the case of dropbox, these urls are random so not programmatic.

I need to find a way to store these images, programmatically store them using a nodeJS script, programmatically access them using JS.

Any ideas?




Fairly simple website development

I have a job to create a decent-looking website that would look like this one.

So my question is which language should I know, besides HTML which I already know quite well...

Keep in mind that I'm not in a rush with this job as it is not for a company, and the website I suggested as a role model is just some site from which I should take the overall idea.

Thank you very much for any answers!




Web server on windows 10 (IIS) accessible through localhost and 127.0.0.1 but not through computer name or IP Address

I recently installed Metasploit on my windows 10 PC. It changed a lot of configurations I think. Now even after uninstalling it I still have that issue.

I'm connected to a wireless network which gives me (192.168.1.100), usually when I type this address it takes me to the same site as (localhost) or (127.0.0.1) but now it doesn't.

Note that I'm trying to access that IP from the same PC not externally.

And ping 192.168.1.100 works, but ping 192.168.1.100:80 does not work. And I'm pretty sure I've tried all the possible configurations for the IIS binding.




hover not working on child divs

here is HTML

    <div class="songsdetails">
        <a href="#" id="c">
            <div class="col-lg-2">
                <div class="songsnumbers">
                    <span>1 -</span><br>
                </div>
            </div>                                  
            <div class="col-lg-8">
                <div class="songsname">
                    <span>Ay Putar Hattan Ty</span><br>
                </div>
            </div>
            <div class="col-lg-2">
                <div class="songduration">
                    <span>4:56</span><br>
                </div>
            </div>
        </a>
            </div>

I want all classes in my a tag to change color if any divisions gets mouse hover. but it isn't working Here's css:

.songsdetails:hover songsnumbers songsname songsduration
{
color:black;
}

Thanks in advance.




vendredi 27 janvier 2017

on selet radio button send ajax call and radio button append using javascript

I'm having trouble after looking at the jQuery docs. I'm just trying to on selet radio button send ajax call and radio button append using javascript. I've tried several things but have not been able to get this right:

         for (var i = 0; i < response.split(',').length; i++) {
            $('#radio_append').append('<input name="suggested_dates" id="suggested_dates'+count+'" value="' + response.split(',')[i] + '" class="styled chal_bhi_radio" type="radio" /><label for="suggested_dates'+count+'">' + response.split(',')[i] + '</label> <br> ')
            count++;
          }

after append this radio button, there are four radio button on click on any one radio button send this ajax call i'm trying several things but did' work...

$(".chal_bhi_radio").on('change',function(){
alert("HI");
  var date_al=$(".chal_bhi_radio:checked").val();
  $.post( "<?php echo $site_root;?>common/service.php?j=4", {date_select: date_al},  
      function( response ) {
        if(response != ''){
             per_data = $.parseJSON(response);
             if(per_data!=0){
                $("#price_special_append").html("");
                add_basic=per_data;
                $("#price_special_append").append(" € "+add_basic+" ")
             }
        }
   });

but on select anyone checkbox it did't show alert box. need help asap thanks community




nodeJS - modify HTML file to display images

I have a static HTML page, and I am using NodeJS to serve that page.

I want to be able to give the HTML page URLS of images dynamically from NodeJS so that those images can be displayed.

How would I do this?




Establish an offline website over local network

I'm very new to all this web design stuff, and i was wondering how to make an offline website accessible through local network such as WiFi connection (no internet access).

The goal is to make the quiz website available to all my students in the class.

Thanks for your answers.




Video calling app creation

I am interested in selecting a project for my masters dissertation which involves creating an app which will allow, amongst other things, creating a two way video link between two devices (I can choose the type of devices if I want).

The complication I have is that when device one calls device two, device two should connect automatically with no user input required, and should be available at all times. Is this sort of thing possible?

I don't currently have any android app development experience, I have created a website with an SQL database attached, JavaScript, and PHP.




how to make a transparent navbar that's not fixed-top?

I want to make transparent navbar in Bootstrap that's not fixed-top but I'm not able to do it with Bootstrap. Should I make it with pure CSS or I can find another option with Bootstrap ?




Argon2 Web Application Java

I recently tested argon2-jvm 2.1 in Apache Tomcat 7.0.33 but when I try to use it I have this exception:

java.lang.UnsatisfiedLinkError: /lib64/libc.so.6: version `GLIBC_2.14' not found 
(required by /opt/tomcat/work/Catalina/localhost/equifax/loader/linux-x86-64/libargon2.so)




Recommend of c# automation jobs for beginner

I had knowledge in building asp.net c# web, but i want to make everthing run by automation , without user manual interact. My jobs is simple which is, check the API respond periodically, if the file is not in my respond list, will proceed to the next part which is upload the file.

For this second part, the automation job will auto go to the website and auto click the interface/user control, and upload the file without human manual interact. After 2 hours, the job will repeat again.

Where can I start in automation, I am considered new in automation jobs? can u give me some idea.

Thank you, appreciated greatly.




How to develop a graph visual editor in javascript?

I need to develop something similar to this : http://draw.io It needs to include :

  • a main canvas
  • toolbars
  • drag'n drop elements from toolbar to canvas
  • link nodes with edges ...

Where to start ? What API or framework should one use ?




Check success of indexeddb createIndex

I'm noticing a decent delay between being able to retrieve results and creation and population of an IndexedDB objectStore. I suspect that the indexing is still running after a large number of "put"s are done, but I'm not sure how to measure each part (createobjectStore, createIndex), and report back.

Is there a simple way to check the success of the index being created?

request.onupgradeneeded = function(e) {
    var db = e.target.result;
    var partsStore = db.createObjectStore("parts", { keyPath: "classID", autoIncrement: true });
     partsStore.createIndex("description", "description", { unique: false });
}




Deploying a one page personal portfolio. Should i be using a framework? Express, ruby on rails..etc

I will be deploying my very first personal portfolio site. Its a single page website. I wanted to know if I should be using a framework like Express.js, or ruby on rails to deploy it.

I have never deployed a website before, so I am not sure what is the best way to go about it. Can someone let me know what they use for they're portfolio website?

Thank you.




jQuery function not executed on subpage

I'm currently developing a website for an university course (Link: http://ift.tt/2jmwPot) and there's an issue I'm not able to solve on my own. I have a "back-to-top" button. With jQuery it lets the page scroll up smoothly.

HTML

<a id="back-to-top" href="#"><i class="fa fa-chevron-circle-up" aria-hidden="true"></i></a>

The following code in my script.js file works fine on the homepage of my website. Unfortunately this doesn't work on any of my subpages.

jQuery

$("#back-to-top").click(function(e){
    e.preventDefault();
    $("html, body").animate({scrollTop: "0"});
});

Do you have any suggestions? Thanks so much in advance!




Auto load void;0 on page load

Hello I need to add a chat function to my apps and the only thing I think is to create in a webview the chat emerge, In my web the chats opens with: javascript:void(Tawk_API.toggle())

so i think in something like this:

enter code here<script type="text/javascript">
function load()
{
window.location.href = "javascript:void(Tawk_API.toggle())";

}
</script>`enter code here`

But no working, could is this possible? I need in this web to on page load auto pop up the widget chat. Thanks!




Web Application without source code

I am developing an enterprise web application and I want to sell it multiple times. But I don’t want to give the source code to them. So, is there any way I can handover the web app to my clients without source code? If YES, please help. But if NO, then how can I handle this issue?




What are all the Necessary things that a new web developer needs to Learn Before creating his First Website?

I and my friend are deciding to take a step in Web Development and Creating a new Website in which some features are complex ! Please tell all the minor and Major or advance things we need to learn for Front end and Back end Development ! We are new to Web Development and want to ask rather than Javascript,html5,css3,bootstrap,php,mysql,jquery is there anything left we need to learn to make our website a fully interactive and functional one !




In what way can I store the answers of an online cryptoquiz website?

I was making this website through which users could play an online quiz sort of game but I don't know how to store the answers so that it is not visible to them when they view the source code or inspect element. I tried using external javascript file but I don't know if this is the right approach.Any better way of doing it?




Is there a way to fetch the data in google search right module

When you do a search on google, you often get a right panel with a lot of information and photos (especially for places)

Is there a way to fetch this data for another usage. (I want to make a guide page on a website where each item could be automatically fed with this data)

enter image description here




AppleScript get text from web without open safari

Is there a way to search text from a page without opening a safari tab?

What I'm trying to do is for example

http://ift.tt/1JaLvz2 &TEXT

Open this URL in background and get the result & set it as a variable




Rotate bottle image in HTML

I'm looking a way to rotate the bottle image in HTML, to achive a similar effect. The idea is to show entire label, not just a fraction of it.

Just masking the label on top of bottle is probably not a good option, as it needs to be "3d" to look natural.




Do modern browsers cache ajax requests?

I have recently found that we use Cache-Control:no-cache in all the WebApi responses. I know that before browsers caching did vary a lot and you never knew if the browser can cache you json, so it was important.

As far as I remember now, no modern browser is caching ajax requests so this header is not needed. But I would really like to double check and ask here about the behavior, since could not found any recent posts on the topic.

So the question really is: Do we still need to set Cache-Control:no-cache for web api calls from SPA application and if yes, then which browsers do the caching?




Best way to implement Football Livescores web app C#

I am developing a Livescores web app with asp.net c#. Server constantly (every second) retrieves big json from API. An array of live Matches that each contains the following: 1) MatchData (light data) 2) Stats (a bit heavier) 3) Events (a bit heavier) 4) Commentaries (a lot of text)

What is best way to implement that kind of behavior so the end user will get every-second updated data on a web page? (Sql server, cache, etc)




Embedding python openCV script in php

I just finished working on a script using python2.7 and openCV, is it possible to call that script and run it on a web browser? if yes, what is the best way to do that? Thanks




How to bundle a clientside Typescript project?

I'm currently trying to get myself some good or best practices for properly using Typescript and I'm struggling to find out how I'm supposed to create a clientside (executed in the browser) bundle of a Typescript project.

Say I have the following directory layout:

[bin]
  banana.js
[ts]
  [components]
    Bar.ts
    Foo.ts
    Moo.ts
  banana.ts
tsconfig.json

I'm using Atom with the atom-typescript extension, so there are some few specific options in the tsconfig.json, but it is downwards compatible. I'm using the default tsconfig.json provided by the extension with a few changes, namely to module, rootDir and outFile.

I've uploaded the sample to a GitHub repo: http://ift.tt/2kst4jh

The bin/banana.js has been compiled by Typescript. The bin/banana.aim.js is what I'm trying to achieve. (Just not sure about the exports.Banana =-statement; should I use exports.default =?)




Student and web-developper at the same time

I'm currently in HND and i wish that i could become (at the same time as my HND) a web developper for private individuals or companies. This might be helpful to me to have a professional experience in this field and to have some money to "pay for" my next year.

I wondered if you knew some websites which proposes this kind of services, someone or anything that may help me in this project ?!

Thanks in advance and have a good day ! :D




Canvas/fabricjs: How to group items?

I have an error when grouping elements. The error is only visible on the circles. Circles are rectangles. How to group items?

var activegroup = canvas.getActiveGroup();
var objectsInGroup = activegroup.getObjects();
activegroup.clone(function (newgroup) {
    canvas.discardActiveGroup();
    objectsInGroup.forEach(function (object) {
        canvas.remove(object);
    });
    canvas.add(newgroup);
});

The full code

Video bug




jeudi 26 janvier 2017

Why isn't Java used for modern web application

I've noticed a trend that out of modern day web startups, a relatively small percentage of them appears to be using Java (compared to Java's overall popularity). When I've asked a few about this, I've typically received a response like, "I hate Java with a passion." But no one really seems to be able to give a definitive answer.

I've also heard this same web startup community refer negatively to Java developers - more or less implying that they are slow, not creative, old.

As a result, I've spent time working to pick up Ruby/Rails, basically to find out what I'm missing. But I can't help thinking to myself, "I could do this much faster if I were using Java," primarily due to my relative experience levels.

But also because I haven't seen anything critical "missing" from Java, preventing me from building the same application.

Which brings me to my question(s):

Why is Java not being used in modern web applications?

Is it a weakness of the language?

Is it an unfair stereotype of Java because it's been around so long (it's been unfairly associated with its older technologies, and doesn't receive recognition for its "modern" capabilities)?

Is the negative stereotype of Java developers too strong? (Java is just no longer "cool")

Are applications written in other languages really faster to build, easier to maintain, and do they perform better?

Is Java only used by big companies who are too slow to adapt to a new language?




Where is the best place or best resources to start learning ethical hacking for web development security?

I am aware of owasp and their GitHub project WebGoat and NodeGoat.

Do you think this is sufficient knowledge for web development security or do you have any other additional recommendations?




use JNI and java servlet or CGI and C lenguage?

I ve to develop web application, I must use a C function server side, and I don t know if it is better use java servlet with JNI freamwork or CGI with C lenguage. I must upload zip file, client side, and use this file with a specific C function. what is the better way? thanks




Loading images to Ajaxswing web application

I would like to convert my desktop app to web app using Ajaxswing and as instructions say, I did all the same: http://ift.tt/2jCKj0a

The thing is that web app starts, but it doesn't load images. I put images to ajax images folder, but server still shows exception:

javax.imageio.IIOException: Can't read input file! at javax.imageio.ImageIO.read(ImageIO.java:1301)

Here is my code:

try {
                img = ImageIO.read(new File("resources/images/blackStone.png"));
                img = img.getScaledInstance(this.pixelSize, this.pixelSize, Image.SCALE_DEFAULT);
                icon = new ImageIcon(img);
                this.setOpaque(true);
                this.setContentAreaFilled(true);
                this.setIcon(icon);
            } catch (IOException e) {
                // TODO Auto-generated catch block
                e.printStackTrace();
            }

Where img is Image,icon is ImageIcon and this is JButton. What should be path to blackStone.png. Any help would be appreciated :)