When I create a constant in class
"Product", then I can use this constant in other classes with Product::id and all is well. :-)
<?php
class Product
{
const id = "4325536";
}
...
But when I try to get a value from URL into const, nothing works:
<?php
class Product
{
const id = $_GET['product'];
}
...
How can I get values from URL into Object?