Skip to content

Instantly share code, notes, and snippets.

View iampava's full-sized avatar
💭
I code and teach JavaScript.

Alexandru Pavaloi iampava

💭
I code and teach JavaScript.
View GitHub Profile
@iampava
iampava / app.php
Created May 17, 2018 08:31
SOAP Web Service in PHP | Author: Lucian Cochior
<?php
define ('WS_URL', 'http://localhost/weather.php');
try {
$client = new SoapClient(null,
array('location' => WS_URL,
'uri' => 'http://web.info/porto', //
'trace' => 1
)
@iampava
iampava / app.php
Created May 17, 2018 08:34
SOAP Web Service in PHP | Author: Lucian Bosinceanu
<?php
define ('WS_URL', 'http://localhost/weather/ws.php');
try {
$client = new SoapClient(null, // nu furnizam niciun WSDL
array('location' => WS_URL, // adresa serviciului Web
'uri' => 'http://web.info/porto', // spatiul de nume corespunzator serviciului Web apelat
'trace' => 1 // se vor furniza informatii de depanare
)
@iampava
iampava / app.php
Created May 17, 2018 08:37
SOAP Web Service in PHP | Sergiu Iacob
<?php
define ('WS_URL', 'http://localhost:1234/lab12/ws.php');
try {
$client = new SoapClient(null, // nu furnizam niciun WSDL
array('location' => WS_URL, // adresa serviciului Web
'uri' => 'http://web.info/porto', // spatiul de nume corespunzator serviciului Web apelat
'trace' => 1 // se vor furniza informatii de depanare
)
);
@iampava
iampava / index.html
Created May 19, 2018 11:52
SOAP Web Service in PHP | Author: Teodor Proca
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8" />
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<title>LAb10</title>
<meta name="viewport" content="width=device-width, initial-scale=1">
<link rel="stylesheet" type="text/css" media="screen" href="main.css" />
<script src="main.js"></script>
@iampava
iampava / Pages.lazy.jsx
Created January 21, 2019 19:31
#1 JavaScript: fast and furious
import Loadable from 'react-loadable';
// Landing page
const LazyLandingPage = Loadable({
loader: () => import('./landing/Landing.page'),
modules: ['./landing/Landing.page'],
webpack: () => [require.resolveWeak('./landing/Landing.page')]
});
const LazyLanding = props => <LazyLandingPage {...props} />;
@iampava
iampava / Root.jsx
Created January 21, 2019 19:31
#2 JavaScript: fast and furious
import {
LazyLanding,
LazyHome
} from './pages/Pages.lazy';
class Root extends React.Component {
render() {
return (
<Switch>
<Route exact path="/" component={LazyLanding} />
@iampava
iampava / app.js
Last active June 9, 2020 07:16
Offscreen Canvas width limitation?
/**
At this canvas width, the normal one gets rendered but the offscreen one is still empty.
However, if you change this to a lower number both will work.
*/
const WIDTH = 20000;
const [firstCanvas, secondCanvas] = document.querySelectorAll('canvas');
firstCanvas.width = WIDTH;
secondCanvas.width = WIDTH;